Skip to content

Commit

Permalink
72 main nav (#264)
Browse files Browse the repository at this point in the history
* 72: first pass of setting up main nav

* fixup! wip.

* fixup! wip.

* Sticky footer mixin.

* Sticky footer mixin.

* 72: fixup

* Update core/scss/utilities/mixins/layout/_sticky-footer.scss

Co-Authored-By: sherakama <[email protected]>

* Update core/scss/utilities/mixins/layout/_sticky-footer.scss

Co-Authored-By: sherakama <[email protected]>

* Update core/scss/utilities/mixins/layout/_sticky-footer.scss

Co-Authored-By: sherakama <[email protected]>

* New grid stuff.

* Sort of refactored.

* Layout - Bricks

* Layout - Basic

* Layout - Battleship.

* 72: put fancy-hover into own mixin file

* Layout - Blastila.

* Layout - Frogger.

* Layout - Pacman.

* Layout - Plakes.

* Layout - Wedge.

* Remove three-column layout from Richard.

* More 2 column layouts.

* Layout - Sunset Delorean.

* Layout - Valmer.

* Refactored Flex Grid with Helpers.

* fixup! wip.

* 72: WIP before vacation

* @mixin sticky-footer now accepts the footer's selector as a parameter

* make styleguide's footer be sticky

* if the brand bar is position:fixed then we really need padding to accommodate it

* fixup! wip.

* grid and breakpoint updates WIP

* Sticky footer and template updates.

* More documentation and comments.

* clean up

* added new modular spacing for 2xl

* Update _alert.scss

* new flex grid approach WIP

* grid column calculation update

* fixup! wip.

* fixup! wip.

* fixup! wip.

* Responsive gutters on flex columns.

* Layout names.

* fixup! wip.

* Grid mixin-a-fied the lockup.

* Solidify layout names.

* 72: WIP

* Update _sticky-footer.scss

* Fix centered column alignment.

* Updates.

* Conditional regions.

* Added type checking and a slightly different parameter to grid-gap.

* 72: WIP with js test

* wip with kss theme.

* 72: WIP and fix CTA icon link

* comment and general cleanup and additions

* 72: WIP

* Refactor KSS theme scss.

* Sort of working new theme.

* More KSS theme tweaks.

* More KSS theme tweaks.

* More KSS theme tweaks.

* Removed debug.

* Update _modular-spacing-get-value.scss

* breakpoints functions folder

* link variants for button options

* rm unstyled button

* empty line CC FIXUP

* CC FIXUP

* CC FIXUP

* 72: clean up and use new grid-media mixin

* Added more documentation.

* worked string comments into kss

* layout FIXUP

* minor layout comment FIXUPs

* wip!.

* Fixers to autoprefixer and updates for IE 11 compatibility.

* More IE Fixes.

* More IE Fixes.

* More IE Fixes.

* More IE Fixes.

* More IE Fixes.

* Update core/scss/components/lockup/_lockup.scss

Co-Authored-By: sherakama <[email protected]>

* flexbox layouts for 1col 2col 4col and fw ; 3col to come

* Flex grid behaviour.

* Flex grid behaviour.

* Flex grid behaviour fixes.

* Flex grid behaviour fixes.

* Auto IE fix for lockup to false.

* Fix for repsonsive colors section.

* updated flex grid demo

* fw 1col 2col and 4col FIXUP and intro of 3col layouts with new flexbox and gutters WIP

* Resolve duplicate twig file name issue by md5 hashing template path and name.

* Update template file names.

* Update template file names.

* Updated blastilla right grid scss.

* Updated blastilla right grid scss.

* Flexbox layouts

* Updated NPM packages and fixed dupe template issue.

* --no-outter-gutter class for flex container

* sr-only FIXUP and rm padding class for flex items

* IE11: Fixes for grid gap.

* More IE fixes.

* Remove margin on flex grid display of KSS.

* wip! flex grid padding rething in progress.

* Flex grid margin gap fixes.

* flex container grid row gap.

* Flex grid vertical rows to bottom only.

* Flex grid vertical rows molive and blastila.

* Added menu toggle button functionality and aria attributes changes; remove 3rd level menu code for now

* Added some documentation to layouts section.

* Code climate fixes.

* Change URL on developer resources main nav item to go to wiki page.

* 72: remove aria roles

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: josephgknox <[email protected]>

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: josephgknox <[email protected]>

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: josephgknox <[email protected]>

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: josephgknox <[email protected]>

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: josephgknox <[email protected]>

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: josephgknox <[email protected]>

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: sherakama <[email protected]>

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: sherakama <[email protected]>

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: sherakama <[email protected]>

* Update core/scss/utilities/variables/core/_gutter.scss

Co-Authored-By: sherakama <[email protected]>

* Update core/templates/layout/flex/four-column/molive/molive.twig

Co-Authored-By: sherakama <[email protected]>

* nom install

* Update core/scss/utilities/variables/core/_grid.scss

Co-Authored-By: sherakama <[email protected]>

* 72: refactor fancy-hover; fixup

* 72: fixup

* 72: js WIP

* 72: js WIP

* 72: js WIP add arrows infinite cycling

* 72: js clean up and refactor with ES6 syntax

* 72: js WIP

* 72: js WIP add keydown listeners depending on where current focus is

* 72: add template debounce function for window resize ends for setting menu toggle aria expanded to false if ends on desktop breakpoint

* 72: IE style fixes

* 72: js WIP

* 72: fixup

* 72: clean up if/else statements

* 72: js fixup

* 72: Add aria-expanded on triggering parent links

* 72: pull menu toggle button out of <nav> in anticipation for when search bar will be added to the expanded section (but not inside <nav>)

* 72: refactor css to respond to --expanded class instead of aria-expanded since that's no longer in the li

* 72: WIP variant with site search on mobile; still need further tweak for multiple instances of main nav

* 72: add light theme

* 72: change twig logic and z-index, svg

* refactor main-nav twig to use structured

* 72: WIP multiple instances

* 72: remove li classes and make li modifiers non-level specific; refactored CSS

* 72: WIP css refactor

* 72: add twig whitespace trimming

* 72: WIP css cleanup and change kss brand bar z-index

* 72: refactor fancy-hover to include options for positions and border thickness

* 72: css cleanup and twig whitespace trimming

* 72: accessibility color/font weight change

* 72: nav color change and add outline back for a:focus

* refactor js

* add additional nav options to styleguid

* change the mobile toggle text in the styleguide

* only search the DOM for the top level nav once in the constructor;
tidy up the code a wee bit

* 72: fixup

* if a subnav item is current, it's parent nav item should also be current

* move ESC key handling from NavItem to Nav; make ESC close one level at a time

* 72: begin cc fixes

* 72: more cc fixes

* Nav doesn't need a depth property;
rename topLevelNav as topNav;
add Nav.getParentNav()

* fix behavior of right & left arrows on desktop

* 72: first batch fixup

* 72: more fixup

* 72: fix transitions

* 72: fixup

* 72: did iterable variable check in twig

* fix issue with tab always closing last subnav, even if not on the last item in the subnav

* close the subnav if Shift+Tab on the first item in subnav

* 72: Add styling for parent li with active children

* 72: add margin on left side of main nav for styleguide full screen mode (LG breakpoint and up)

* don't preventDefault() on clicks on subnav items (!)

* allow specifying arbitrary attributes on nav links

* no need to test if list_items is not empty - just throw an error in that case

* 72: modify click behavior so when submenu is open, it doesn't focus on 1st item (only for keyboard users); js spacing tweaks; refactored some em values because of new base font sizes

* Update core/js/decanter.js

Co-Authored-By: yvonnetangsu <[email protected]>

* 72: add enter/spacebar key behavior; more em value refactoring

* 72: desktop CSS fix to accommodate new click behavior; set nav display to block

* 72: more CSS refactor due to different click/keyboard behavior; cleanup

* 72: button styles

* add lots of JSDoc; rewrite one line helper methods as arrow functions

* remove TODO comment

* Enabled ESLint

* Enabled ESLint. Removed filter.

* Enabled ES6 syntax in eslintrc.

* Added to ignore list.

* Added max-len to lintrc

* render nav fully expanded on desktop when no JS - UGLY!!!

* 72: fix error with removing 'no-js'

* 72: when no js, submenu on desktop expands on hover, expand all submenus on mobile; fix multiple main nav z-index in styleguide for no-js

* 72: small fix with z-index in kss scss

* 72: make submenu a bit narrower; give styleguide right-align variant right margin so submenu doesn't get covered up when expanded

* 72: svg and minor css fixup

* Firefox doesn't like arrow functions as class methods

* 72: add toggle modifier classes to center and right align hamburger button

* fix Firefox tab issue

* 72: cc fix

* Removed uglification.

* Removed uglification.

* fixup! cc.

* fixup! cc.

* fixup! cc.

* fixup! cc.

* fixup! cc.

* fixup! cc.

* fixup! cc.

* fixup! cc.

* fixup! cc.

* fixup! cc.

* fixup! cc.

* Update main-nav.twig

* Update main-nav.twig
  • Loading branch information
yvonnetangsu authored Mar 6, 2019
1 parent 9a36620 commit 33d92a7
Show file tree
Hide file tree
Showing 41 changed files with 2,472 additions and 142 deletions.
6 changes: 4 additions & 2 deletions .codeclimate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ engines:
# https://docs.codeclimate.com/docs/eslint
# ES Linting requires an .eslintrc file to tweak checks.
eslint:
enabled: false
enabled: true
markdownlint:
enabled: true
checks:
Expand Down Expand Up @@ -80,5 +80,7 @@ exclude_patterns:
- "node_modules"
- "styleguide"
- "kss/**/*"
- "core/js"
- "core/scss/core/_normalize.scss"
- "Gruntfile.js"
- "composer.json"
- "package.json"
28 changes: 25 additions & 3 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -1,13 +1,36 @@
{
"extends": "eslint:recommended",
"env": {
"browser": true
"browser": true,
"es6": true
},
"globals": {
"domready": true
},
"ecmaFeatures": {
"arrowFunctions": true,
"blockBindings": true,
"classes": true,
"defaultParameters": true,
"destructuring": true,
"forOf": true,
"generators": true,
"modules": true,
"objectLiteralComputedProperties": true,
"objectLiteralDuplicateProperties": true,
"objectLiteralShorthandMethods": true,
"objectLiteralShorthandProperties": true,
"regexUFlag": true,
"regexYFlag": true,
"restParams": true,
"spread": true,
"superInFunctions": true,
"templateStrings": true,
"unicodeCodePointEscapes": true,
"globalReturn": true
},
"rules": {
// Errors.
"max-len": [2, 80, 2, {"ignoreUrls": true}],
"array-bracket-spacing": [2, "never"],
"block-scoped-var": 2,
"brace-style": [2, "stroustrup", {"allowSingleLine": true}],
Expand Down Expand Up @@ -73,7 +96,6 @@
"spaced-comment": [2, "always"],
"strict": [2, "function"],
"yoda": [2, "never"],
// Warnings.
"max-nested-callbacks": [1, 3],
"valid-jsdoc": [1, {
"prefer": {
Expand Down
15 changes: 3 additions & 12 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,6 @@ module.exports = function(grunt) {
},
target: ['core/scss/\*\*/\*.scss']
},
uglify: {
my_target: {
files: {
'core/js/decanter.min.js': 'core/js/decanter.js',
}
}
},
postcss: {
options: {
map: true, // inline sourcemaps
Expand All @@ -76,8 +69,7 @@ module.exports = function(grunt) {
}
},
jsmin: {
files: ['core/**/*.js'],
tasks: ['uglify']
files: ['core/**/*.js']
},
twig: {
files: ['**/*.twig', '**/*.json'],
Expand Down Expand Up @@ -143,7 +135,6 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-run');
grunt.loadNpmTasks('grunt-browser-sync');
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-sass');
grunt.loadNpmTasks('grunt-sass-lint');
grunt.loadNpmTasks('grunt-contrib-watch');
Expand All @@ -152,9 +143,9 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-copy');

grunt.registerTask('deploy', ['styleguide', 'deploy_site:styleguide', 'clean:postdeploy']);
grunt.registerTask('styleguide', ['compile', 'uglify', 'clean:styleguide', 'run:styleguide', 'copy:styleguide']);
grunt.registerTask('styleguide', ['compile', 'clean:styleguide', 'run:styleguide', 'copy:styleguide']);
grunt.registerTask('compile', ['sass:dist', 'postcss:dist']);
grunt.registerTask('dev', ['styleguide', 'browserSync', 'watch']);
grunt.registerTask('default', ['watch']);
grunt.registerTask('default', ['dev']);

}
Loading

0 comments on commit 33d92a7

Please sign in to comment.