Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UIKit Refactor Part 8: Nav, Viewport, Header & More! #973

Merged
merged 38 commits into from
Jul 16, 2019

Conversation

sghoweri
Copy link
Contributor

Builds off of #960 -- with this PR we're almost completely moved into the new UIKit codebase!

In a nutshell, this PR:

  1. Adds a workaround to a strange Webpack (and possibly Preact) bug when compiling in production mode causing some UI components to not show up as expected. While that bug is still present (fix TBD), the build process updates here significantly optimize what we have -- shaving nearly 1.5MBs off the compiled CSS and JS!
  2. Ports over most of the remaining Pattern Lab UI components over to the new refactored codebase.
  • This including refactoring the navigation / dropdown menu, viewport / iframe, viewport controls, the header, and the contextual menu to all now be rendered as standalone web components (using Preact and SkateJS)
  1. Starts the process of breaking apart the massive chunk of styleguide.js logic to start to have things live with the associated component and/or be pulled out into a shared JS utility function that components pull in as a shared dependency
  2. Removes most of the remaining Hogan.js templating logic / HTML includes and inline templates since Pattern Lab's UI components can now render their own markup themselves 😉

More to come -- we're almost at the finish line!! 🎉

…all PL layout, cross browser fixes and scrolling improvements. add prettier and prettier-quick dev-dependencies to always run, even when not globally available
…s to know if you can scroll and if so, in what direction
…he latest refactored component Sass + legacy partials in alphabetical order
# Conflicts:
#	packages/uikit-workshop/dist/styleguide/js/patternlab-viewer.js
#	packages/uikit-workshop/package.json
#	packages/uikit-workshop/src/scripts/utils/polyfills.js
# Conflicts:
#	packages/uikit-workshop/dist/index.html
#	packages/uikit-workshop/dist/styleguide/css/pattern-lab.css
#	packages/uikit-workshop/dist/styleguide/js/patternlab-pattern.js
#	packages/uikit-workshop/dist/styleguide/js/patternlab-viewer.js
#	packages/uikit-workshop/package.json
#	packages/uikit-workshop/src/html/index.html
#	packages/uikit-workshop/src/html/partials/modal.html
#	packages/uikit-workshop/src/sass/pattern-lab.scss
#	packages/uikit-workshop/src/sass/scss/04-components/_header.scss
#	packages/uikit-workshop/src/sass/scss/04-components/_navigation.scss
#	packages/uikit-workshop/src/sass/scss/04-components/_pattern-info.scss
#	packages/uikit-workshop/src/sass/scss/04-components/_tabs.scss
#	packages/uikit-workshop/src/sass/scss/04-components/_viewport.scss
#	packages/uikit-workshop/src/sass/scss/05-themes/_light-theme.scss
#	packages/uikit-workshop/src/scripts/components/pl-drawer/pl-drawer.scss
#	packages/uikit-workshop/src/scripts/components/pl-layout/pl-layout.scss
#	packages/uikit-workshop/src/scripts/components/pl-search/pl-search.scss
#	packages/uikit-workshop/src/scripts/patternlab-pattern.js
… controls into separate smaller components; break out up theming specific CSS into the specific components being styled
… bits of UI logic scattered around the codebase;
…replaced by standalone web components that individual handle their own UI
…index.html file to remove old templates no longer used + update to use latest web component tags
…be better optimized for production — workaround to the normal production mode not fully rendering all components as expected
…tern-specific UI like accordions not working when patterns are viewed as a standalone HTML page
…uikit-refactor-p8

# Conflicts:
#	packages/uikit-workshop/package.json
@bradfrost
Copy link
Member

@sghoweri Thanks so much for this! What needs to happen in order for this to get merged in?

@sghoweri
Copy link
Contributor Author

sghoweri commented Dec 4, 2018

@sghoweri Thanks so much for this! What needs to happen in order for this to get merged in?

Thanks @bradfrost! That’s a really good question... the biggest thing blocking this from getting merged in is probably #960 not yet being merged in (which I’m also not 100% clear on what’s needed — if anything — before we merge that in).

My gut tells me to merge this and #960 and cut another UIKit beta ASAP so we can focus on wrapping up any potential bugs and remaining updates (CSS Variables for theming!!), especially if there’s really isn’t a ton of added risk (beta release FTW).

@bmuenzenmeyer thoughts?

@bmuenzenmeyer
Copy link
Member

@bmuenzenmeyer thoughts?

Our last communication still stands, IMO. #960 (comment)

We were hoping to fix #890 before #960. I left some breadcrumbs after having limited time to debug it the last couple weeks. #890 (comment)

…uikit-refactor-p7

# Conflicts:
#	packages/uikit-workshop/package.json
# Conflicts:
#	packages/uikit-workshop/dist/styleguide/css/pattern-lab.css
#	packages/uikit-workshop/dist/styleguide/js/patternlab-pattern.js
#	packages/uikit-workshop/dist/styleguide/js/patternlab-viewer.js
#	packages/uikit-workshop/dist/styleguide/js/pl-drawer~pl-layout~pl-search~pl-toggle-info~pl-toggle-layout~pl-toggle-theme-chunk-2c67daaa66841dd22518.js
#	packages/uikit-workshop/dist/styleguide/js/pl-modal-viewer-chunk-f38ef759072e3833b962.js
#	packages/uikit-workshop/dist/styleguide/js/pl-search-chunk-129bc9ed93061bd70d16.js
#	packages/uikit-workshop/dist/styleguide/js/vendors~pl-layout-chunk-1ff0599dcdd07d03f1dd.js
@stale
Copy link

stale bot commented Apr 3, 2019

It's hard to keep track of everything. This issue has been automatically marked as stale because it has not had recent activity, neither from the team nor the community. It will be closed if no further activity occurs. Please consider adding additional info, volunteering to contribute a fix for this issue, or making a further case that this is important to you, the team, and the project as a whole. Thanks!

@sghoweri
Copy link
Contributor Author

sghoweri commented Apr 3, 2019

Also bump. I also owe @bradfrost some PR review info on this one as well #drupalcon

sghoweri added a commit to sghoweri/patternlab-node that referenced this pull request Apr 16, 2019
@stale
Copy link

stale bot commented Jun 2, 2019

It's hard to keep track of everything. This issue has been automatically marked as stale because it has not had recent activity, neither from the team nor the community. It will be closed if no further activity occurs. Please consider adding additional info, volunteering to contribute a fix for this issue, or making a further case that this is important to you, the team, and the project as a whole. Thanks!

@bmuenzenmeyer
Copy link
Member

seeing some odd behavior in Firefox where the nav renders differently

image

chome:

image

not going to let that stop us

@bmuenzenmeyer bmuenzenmeyer merged commit 6c3dcf4 into pattern-lab:dev Jul 16, 2019
@bradfrost
Copy link
Member

@bmuenzenmeyer I can take a look at that bug, but would need a refresher on how to fire this up to deal with it!

@bmuenzenmeyer
Copy link
Member

👋
I think this will get you there:

git checkout dev
npm install && npm run bootstrap
cd packages/uikit-workshop
npm run build //npm run watch may work too but havent tried it
cd ../development-edition-engine-handlebars
npm run pl:serve

any changes require rebuilding the workshop - may be easier to open two terminals.

antonia-rose pushed a commit to quelltexterin/nemo-uikit-workshop that referenced this pull request Apr 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants