From 5296686423e2d38aa66fca0a4449f41f51182176 Mon Sep 17 00:00:00 2001 From: Paul C Pederson Date: Mon, 12 Jan 2015 11:35:14 -0800 Subject: [PATCH 1/4] add guid to all data entries --- docs/source/table_of_contents.yml | 101 ++++++++++++++++++++++++++++++ 1 file changed, 101 insertions(+) diff --git a/docs/source/table_of_contents.yml b/docs/source/table_of_contents.yml index cd0b1350d..64b10334b 100644 --- a/docs/source/table_of_contents.yml +++ b/docs/source/table_of_contents.yml @@ -5,22 +5,30 @@ get-started: - group: 'Get Started' pages: - title: 'Overview' + id: '0e93f7c2-6302-4724-a15a-a32c2592be38' link: get-started - title: 'Static Files' + id: 'b8750ed0-85a9-4640-9644-7afe84e708c1' link: static-files - title: 'Ruby Gem' + id: '28241474-c950-4ae3-84ec-374a5513804c' link: ruby-gem - title: 'NPM' + id: '5ddecbb1-3f18-4603-9b67-5c927673fae1' link: npm - group: 'Contributing' pages: - title: 'Install' + id: '53a4132e-ce9f-4e10-bf10-366778372167' link: install - title: 'Development' + id: '99ea74b8-7a26-4dd2-8944-e82dcb1d39cb' link: development - title: 'Versioning' + id: 'd1002cfd-11e1-4720-b05d-60b1f057c818' link: versioning - title: 'Deploying the Documentation' + id: '323de7b8-663b-4ee2-8ff8-b8068171d9a0' link: deploy-the-documentation type: @@ -30,8 +38,10 @@ type: - group: 'Typefaces' pages: - title: 'Overview' + id: '0c1050c6-27df-4a9f-b7a3-bea7b0b0954b' link: overview - title: 'Header Face' + id: '6918aafb-dbc4-4508-b73a-01cc4711af1d' link: header-face modifiers: - header-light @@ -42,12 +52,14 @@ type: - header-demi-italic - header-bold-italic - title: 'Body Face' + id: 'd8652d8a-f86e-4aae-be91-a0e496ca96fc' link: body-face modifiers: - body-face - body-italic - body-bold - title: 'Secondary Face' + id: '5c57b63b-f9af-450a-8f0c-b877ef2ee8bf' link: secondary-face modifiers: - secondary-face @@ -55,14 +67,17 @@ type: - secondary-bold - secondary-bold-italic - title: 'Code Face' + id: '0e6fb89b-ec62-49c1-a076-61d15693c4c8' link: code-face modifiers: - code-face - group: 'Composition Helpers' pages: - title: 'Overview' + id: '76ae62a6-f8cb-4e60-92de-5c1d7013a985' link: composition-helpers - title: 'Text modifiers' + id: 'fca01d0c-a767-45e7-b7c1-c76df4dbf235' link: text-modifiers modifiers: - text-large @@ -75,6 +90,7 @@ type: - text-left - text-right - title: 'Color' + id: 'f2002b89-6a32-40de-aee8-dac683459c18' link: text-color modifiers: - text-red @@ -91,6 +107,7 @@ type: - text-darkest-gray - text-off-black - title: 'Link Color' + id: '491ab42e-ce0a-4f62-a174-932a96d3374e' link: link-color modifiers: - link-red @@ -107,16 +124,19 @@ type: - link-darkest-gray - link-off-black - title: 'Bulleted List' + id: '09911685-b661-48e0-be49-3dac2159ab58' link: list-bulleted modifiers: - list-bulleted - title: 'Numbered List' + id: 'c6aa58c9-3654-4e58-9eca-2eeb6765ac87' link: list-numbered modifiers: - list-numbered - group: 'Defaults' pages: - title: 'Overview' + id: 'c77ab0ff-109f-4324-bdb5-19b2649dcea4' link: type-defaults grid: title: 'Grid' @@ -125,28 +145,39 @@ grid: - group: 'Grid' pages: - title: 'Overview' + id: '3289a3b7-40c1-4f8a-a091-24f85e8ac50e' link: overview - title: Configuration + id: 'e250b7ce-88d4-49c4-921f-0250963f246b' link: configuration - title: 'Container' + id: '4f3afff4-4307-49d9-89f5-d72e74428f74' link: container - title: 'Columns' + id: '59bb117c-3d4a-4118-be8f-ce4f6c82f6c1' link: columns - title: 'Responsive Columns' + id: '2b507129-e407-4e1d-b391-4f34f004c7b2' link: responsive-columns - title: 'Nested Columns' + id: '213d4570-e92a-4cb0-ac03-f0b756e28cd0' link: nested-columns - title: 'Rows' + id: 'b85a062f-c886-484a-99f9-10c8a7abb35d' link: rows - title: 'Block Groups' + id: '0a02534e-1f3d-4366-8431-d8d5b0bd159f' link: block-groups - title: 'Responsive Block Groups' + id: 'fde4e890-c67e-485f-b194-69673542d237' link: responsive-block-groups - group: 'Grid Helpers' pages: - title: 'Pre & Post' + id: 'a33b3232-7401-4bcd-8b6f-82e8d797ae2a' link: pre-and-post - title: 'Leader & Trailer' + id: '9579cd13-2f03-4457-98a6-661085e1fdf7' link: leader-and-trailer modifiers: - leader-0 @@ -178,20 +209,27 @@ grid: - padding-trailer-5 - padding-trailer-6 - title: 'First & Last' + id: '655ca374-bd47-4fe4-9a4d-e3c259c57458' link: first-and-last - title: 'Show & Hide' + id: '6eff5153-abea-42e1-9cb2-000b1409e638' link: show-and-hide - title: 'Left & Right' + id: '48beff7a-ef70-4fb7-ac96-af8436dcb243' link: left-and-right - title: 'Inline' + id: '52a300e2-4415-444c-9ffb-1326637e88dc' link: inline - group: 'Interactive Layout Helpers' pages: - title: 'Overview' + id: '1a74846a-39ee-437b-bce2-c4c2535e7276' link: interactive-layout-helpers - title: 'Scroll Show & Hide' + id: '10a12805-c75a-4b38-bea6-287759d8f868' link: scroll-show-and-hide - title: 'Scroll Sticky' + id: '35f1c06e-c344-4d83-8b68-8c0828d6ab37' link: scroll-sticky icons: @@ -201,11 +239,14 @@ icons: - group: 'Icon Sets' pages: - title: 'Overview' + id: '7234c859-df11-4fed-80ca-c4626fbe89bc' link: overview - title: 'Icon Font' + id: '498a8593-caea-4ea3-8d50-1b60f923ff5b' link: font folder: 'lib/img/icons/calcite-large/*.svg' - title: 'Color Icons' + id: '6587644f-5306-43b7-b736-b02d0605516c' link: color folder: 'lib/img/icons/vecticons/*.svg' @@ -216,8 +257,10 @@ color: - group: 'Palette' pages: - title: 'Overview' + id: '59e05d70-8952-43d4-bc1f-c121b08fe943' link: overview - title: 'Grayscale' + id: '0d5b6033-a27c-4d16-aca8-67aa78fe2d8c' link: grayscale colors: - white @@ -234,6 +277,7 @@ color: - transparent-black - transparent-off-black - title: 'UI Colors' + id: '35333048-5b8b-427d-baf2-a069bfa995f4' link: ui-colors colors: - lightest-blue @@ -260,6 +304,7 @@ color: - brown - dark-brown - title: 'Type Colors' + id: 'befed6dc-7581-40d9-a518-b1488213d55e' link: type-colors components: @@ -269,8 +314,10 @@ components: - group: 'Components' pages: - title: 'Overview' + id: 'f3abfe1e-d55b-4fc0-9bbf-4a0f759d44de' link: overview - title: 'Buttons' + id: 'c69d9df6-f58c-4d5b-9b72-688e9c67ca64' link: buttons modifiers: - btn-arrow @@ -296,34 +343,42 @@ components: - btn-darkest-gray - btn-off-black - title: 'Button Groups' + id: 'd6b176ee-cc95-45f8-8db9-a3f557bac4d9' link: button-groups modifiers: true - title: 'Dropdowns' + id: '2fabab1c-0017-42d1-b4f5-52421ae630ed' link: dropdowns modifiers: - dropdown-right - title: 'Loader' + id: '136f44d9-7e03-4869-9a5d-6177a9831a5b' link: loader modifiers: true - title: 'Alerts' + id: '9a6b6e52-3860-4fbc-8917-fb02636c8ed9' link: alerts modifiers: - alert-red - alert-green - title: 'Panels' + id: '6c29e0a4-4e14-4c98-9edf-1d348ce6f553' link: panels modifiers: - panel-dark - panel-white - title: 'Breadcrumbs' + id: 'f6281457-56ae-4edd-bd23-149531e9a731' link: breadcrumbs modifiers: true - title: 'Tooltips' + id: '19e8dbb4-f877-40ec-9344-8655c4e261b6' link: tooltips modifiers: - tooltip-left - tooltip-right - title: 'Tables' + id: '21d0b59b-bb08-4aac-a486-880891246ba2' link: tables modifiers: - table-blue @@ -332,28 +387,35 @@ components: - group: 'Forms' pages: - title: 'Form Overview' + id: '8fbc1527-ab31-4c93-af2f-1761116d178c' link: form-overview modifiers: true - title: 'Search Bar' + id: '06ae4847-e8ff-4270-8897-e2ad5fc9c52d' link: search-bar modifiers: true - title: 'Text Inputs' + id: '2845e289-ccce-4f3e-b825-4e2a8d6395d9' link: text-inputs modifiers: - 'input-error' - title: 'Selects' + id: '7326581a-f2f5-42be-9a46-d79faec27253' link: selects modifiers: - input-error - title: 'Checkboxes' + id: 'd745e424-540c-4ee3-954b-27bd1a121ee9' link: checkboxes modifiers: true - title: 'Radio Buttons' + id: '9004bf43-d962-43e7-a5b8-8bc0905557ea' link: radio-buttons modifiers: true - group: 'Branding' pages: - title: 'Esri Logo' + id: 'ecacdf63-466d-4897-b597-0357a8833427' link: esri-logo modifiers: - 'esri-logo-reverse' @@ -364,52 +426,68 @@ patterns: - group: 'Patterns' pages: - title: 'Overview' + id: '102c73b6-ac62-4ef7-b74b-0adb04a5a9f6' link: overview - title: 'Basic Page' + id: '8c6b323a-b24c-4a2e-841b-a349f1262322' link: basic-html-page - title: 'Top Nav' + id: '4fd8bd45-2b8e-4a40-af68-fa96e6de13af' link: top-nav modifiers: true - title: 'User Sign In' + id: 'b5e31f9b-4f04-40bc-9dde-e56f24b4604d' link: user-sign-in modifiers: - sign-in - title: 'User Nav' + id: 'f31d7b16-9788-4d3e-821b-902f9b77937b' link: user-nav modifiers: true - title: 'Sub Nav' + id: '1636ba83-321f-4bbd-8f20-a9ff6c749f41' link: sub-nav modifiers: true - title: 'Third Nav' + id: 'a54ce149-a63f-4e69-9fb4-671880061a40' link: third-nav modifiers: true - title: 'Side Nav' + id: '6e6b700d-62e4-4651-87df-78fee8bd1120' link: side-nav modifiers: true - title: 'Footer' + id: '72f7f8cf-3c9f-460c-b5d1-597a42a8f10c' link: footer - title: 'Pagination' + id: 'aa4653d3-0283-4f3a-92ff-ff736ab11e83' link: pagination modifiers: true - group: 'Interactive Patterns' pages: - title: 'Modals' + id: 'a066105f-aa00-4b7a-8d84-2b5db2d9fbb5' link: modals modifiers: true - title: 'Tabs' + id: '1f77faa4-b6f2-4b00-bd5f-f357da5814e0' link: tabs modifiers: - 'tabs-gray' - 'tabs-transparent' - title: 'Accordions' + id: '93e95ff8-0ad4-478b-b1c4-d87a34486b05' link: accordions modifiers: true - title: 'Carousels' + id: 'c5ffc172-f526-4952-a18f-9f06a7d9724c' link: carousel modifiers: true - title: 'Drawers' + id: 'e538b8cd-ce5e-4f86-823a-ebb5ec041039' link: drawers - title: 'Expanding Nav' + id: '60b94e36-5263-494d-85a5-828b4379d6dd' link: expanding-nav modifiers: true sass: @@ -419,31 +497,42 @@ sass: - group: 'Sass' pages: - title: 'Overview' + id: 'caefd32d-f525-4d88-8558-f2f5336fca58' link: overview - group: 'Variables' pages: - title: 'Overview' + id: 'd7dd7bef-8663-46c2-83a0-2879638b8e88' link: variables - title: 'Breakpoints' + id: '5d7bc93b-2030-4150-acd2-086582d9c9f1' link: breakpoints - title: 'UI Variables' + id: '5a1759db-3818-422b-8f9f-863ef1849b67' link: 'ui-variables' - group: 'Type Composition' pages: - title: 'Type Composition' + id: 'fd29d552-426e-4a6e-9988-b9caad79cdf1' link: type-composition - title: 'Font Size' + id: '585869bd-5bc5-4c36-b3f0-f9c44acaa0bb' link: font-size - title: 'Modular Scale' + id: '3f0e370f-8901-49db-a537-2deacaa1d12d' link: modular-scale - title: 'Tracking' + id: '8a11b8b2-a98a-436c-b082-abbb03e8d2aa' link: tracking - title: 'Leading' + id: '413a58a8-12fa-47c4-95e3-a771cdb000ea' link: leading - title: 'Word Spacing' + id: '0e37d6f4-a571-408c-92d6-c1edeac71db7' link: word-spacing - title: 'Unicode Variables' + id: 'aa2293d9-1e16-4add-9e70-f49dbebec7ae' link: unicode-variables variables: - nbsp @@ -494,6 +583,7 @@ sass: - group: 'Utilities' pages: - title: Utility Mixins + id: '1456a860-3e4d-4f99-b443-9ba179ca65e1' link: utility-mixins javascript: @@ -503,16 +593,21 @@ javascript: - group: 'Interactive Patterns' pages: - title: 'Overview' + id: '3a6b6c9f-9108-4546-a8fe-2dcbca936b11' link: overview - group: 'Utility Functions' pages: - title: 'Overview' + id: '774add83-6f64-45d3-aedb-e36b147ee3da' link: utility-functions - title: 'DOM Utilities' + id: '1c2831b4-e10a-48c8-a973-553612a2757d' link: dom-utilities - title: 'Array Manipulation' + id: '685846d5-4624-4517-b4ce-a52f1d831811' link: array-manipulation - title: 'Browser Feature Detection' + id: '55213a54-ebac-4ca3-9664-b2686f5975ae' link: browser-feature-detection layouts: @@ -522,14 +617,20 @@ layouts: - group: 'Building Layouts' pages: - title: 'Homepage' + id: 'c67b8815-4f70-4759-b8aa-128beb04624b' link: homepage - title: 'Landing Page' + id: 'b81a5ca4-3d82-41bc-b855-38114245d411' link: landing-page - title: 'Documentation' + id: 'e08f8684-5b33-4b2c-bb89-6333666fd85e' link: documentation - title: 'Web App' + id: 'fc8fd951-037e-475f-b5ba-e685b9ca7213' link: web-app - title: 'Fullscreen Map App' + id: '42a18449-3de0-4e3f-8b0a-cbaad3046ca4' link: fullscreen-map-app - title: 'Embedded Map App' + id: '5d2329cb-849f-43f9-9d92-f3f7935dcee2' link: embedded-map-app From e0256d8a182600df57f8299d10e6c13784a5999b Mon Sep 17 00:00:00 2001 From: Paul C Pederson Date: Mon, 12 Jan 2015 12:21:38 -0800 Subject: [PATCH 2/4] update schema of deploy script --- deploy.js | 61 ++++++++++++++++++++++++++++++++----------------------- 1 file changed, 36 insertions(+), 25 deletions(-) diff --git a/deploy.js b/deploy.js index 74f6e8689..ac10cde7d 100644 --- a/deploy.js +++ b/deploy.js @@ -8,39 +8,43 @@ var jf = require('jsonfile'); var path = require('path'); var yaml = require('js-yaml'); -var file = 'dist/content.json'; -var response = []; +var file = 'docs/build/content.json'; +var response = { + elements: [], + colors: [] +}; function constructItem(content, meta) { var item = { - group: meta.group, - groupOrder: meta.group_order, - page: meta.page, - page_order: meta.page_order, - page_slug: meta.page_slug, + _id: content.id, title: content.title, slug: content.link, - tags: ['calcite-web', 'web', content.title, meta.group, meta.page], - order: meta.order + tags: ['calcite-web', 'web', content.title, meta.group, meta.page, meta.page_slug], + sort_order: meta.order } - var markdownPath = path.join('docs', 'source', item.page_slug, '_' + item.slug + '.md'); + var markdownPath = path.join('docs', 'source', meta.page_slug, '_' + item.slug + '.md'); var markdown = fs.readFileSync(markdownPath, 'utf8'); item.description = JSON.stringify(markdown); if (content.modifiers) { item.modifiers = content.modifiers; - var samplePath = path.join('docs', 'source', item.page_slug, 'sample-code', '_' + item.slug + '.html'); + var samplePath = path.join('docs', 'source', meta.page_slug, 'sample-code', '_' + item.slug + '.html'); var sample = fs.readFileSync(samplePath, 'utf8'); item.sample_code = JSON.stringify(sample); } - response.push(item); + if (meta.group == 'Palette') { + response.colors.push(item); + } else { + response.elements.push(item); + } + } -var contents = yaml.safeLoad(fs.readFileSync('data/table_of_contents.yml', 'utf8')); +var contents = yaml.safeLoad(fs.readFileSync('docs/source/table_of_contents.yml', 'utf8')); var counter = 0; for (var key in contents) { @@ -52,8 +56,18 @@ for (var key in contents) { contents[key].navigation.forEach(function (group, index){ meta.group = group.group; meta.group_order = index; + + var orderArray = []; + + for (var i = group.pages.length; i > 0; i--) { + orderArray.push(i); + } + group.pages.forEach(function (element, i){ - meta.order = i; + meta.order = orderArray[i]; + if (element.title == 'Overview') { + meta.order == 100; + } constructItem(element, meta); }); }); @@ -62,14 +76,11 @@ for (var key in contents) { jf.writeFileSync(file, response); - -// sort_order: higher-numbers are higher on page, overviews are 100, default 0 -// sort reponse into three keys: elements, color, icons - -// use this guid generator and add a guid to every item -// function guid(){ -// return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) { -// var r = Math.random()*16|0, v = c == 'x' ? r : (r&0x3|0x8); -// return v.toString(16); -// }); -// } +module.exports.guid = function () { + return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) { + var r = Math.random()*16|0, v = c == 'x' ? r : (r&0x3|0x8); + var id = v.toString(16) + console.log(id); + return id; + }); +}; From b899b45dedcfaeebbbe46f47771edf306b7ed572 Mon Sep 17 00:00:00 2001 From: Paul C Pederson Date: Mon, 12 Jan 2015 14:11:49 -0800 Subject: [PATCH 3/4] bump to 0.0.7 --- CHANGELOG.md | 8 ++++++++ package.json | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6c259f5d9..ed8455a81 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,10 +1,14 @@ ## v0.0.7 +Javascript, documentation, and more patterns. + ### Added - sticky scroll - sticky show - javscript for interactive patterns - invisible class +- carousel pattern +- `transition-prefixed()` mixin ### Modified - Minor padding right compression on .top-nav-title @@ -14,6 +18,10 @@ - Minor adjustments on font-size at values less than 0 - alpha counters on nested ol - ITC Charter to Kepler +- Major rework of documentation tech stack + +### Removed +- Color Map ## v0.0.6 diff --git a/package.json b/package.json index 736930abb..2e0cbec1e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "calcite-web", - "version": "0.0.6", + "version": "0.0.7", "description": "SASS & CSS Framework for Esri websites", "private": true, "homepage": "https://github.com/esri/calcite-web", From e9cfc7d32f9d53bafb9a8b11489fcfd0760d753b Mon Sep 17 00:00:00 2001 From: Paul C Pederson Date: Mon, 12 Jan 2015 14:12:06 -0800 Subject: [PATCH 4/4] document transition-prefixed --- docs/source/sass/_utility-mixins.md | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/docs/source/sass/_utility-mixins.md b/docs/source/sass/_utility-mixins.md index f21d111d5..26e60a846 100644 --- a/docs/source/sass/_utility-mixins.md +++ b/docs/source/sass/_utility-mixins.md @@ -145,7 +145,7 @@ This mixin provides a shorthand syntax and supports multiple transitions. @include transition(opacity 1.0s ease-in 0s, width 2.0s ease-in 2s); ``` -To transition vendor-prefixed properties, e.g. `-webkit-transform` and `-moz-transform`, do not use the shorthand mixin. Instead, use the individual transition mixins: +Or you can use the individual transition properties: ``` @include transition-property(transform); @@ -154,6 +154,16 @@ To transition vendor-prefixed properties, e.g. `-webkit-transform` and `-moz-tra @include transition-delay(0.5s); ``` +#### Transition Prefixed + +To transition vendor-prefixed properties, e.g. `-webkit-transform` and `-moz-transform`, there is an additional convinience `transition-prefixed()` mixin: + +``` +@include transition-prefixed(transform3d(0,0,0) 200ms linear); +``` + +This will generate vendor prefixed properties *and* values. + #### Show and Hide The show and hide mixins change the `visibility` property. This is useful for removing and adding elements at certain breakpoints or with certain class names. No arguments are passed.