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

Gutenboarding: add header #36525

Merged
merged 12 commits into from
Oct 21, 2019
Merged

Gutenboarding: add header #36525

merged 12 commits into from
Oct 21, 2019

Conversation

simison
Copy link
Member

@simison simison commented Oct 4, 2019

Adds a basic header canvas with an example button.

As next steps outside this PR we need to somehow ensure that .layout__content and Calypso CSS reset styles don't collide with block editor.

In this PR we introduce a bunch of Gutenberg stylesheets in Calypso, but those should be in future imported via base-styles package, being worked at WordPress/gutenberg#17883.

Testing

  • Visit /gutenboarding in development env and confirm that you see a header that doesn't do anything yet. :-)
  • Confirm that CSS reset isn't leaking to rest of Calypso

@matticbot
Copy link
Contributor

@chriskmnds
Copy link
Contributor

chriskmnds commented Oct 5, 2019

Looks like a bit of a structure emerging. How about something like this for the additional content:

./assets/
- stylesheets/
- stylesheets/main.scss
- stylesheets/gutenberg/
- stylesheets/gutenberg/_animations.scss 
- stylesheets/gutenberg/_breakpoints.scss
- stylesheets/gutenberg/_colors.scss 
- stylesheets/gutenberg/_mixins.scss
- stylesheets/gutenberg/_variables.scss
- stylesheets/gutenberg/_z-index.scss

./src/
- components/
- components/header/
- components/header/index.tsx
- components/header/style.scss
- components/inserter/
- components/inserter/index.tsx 

We can do more with the rest too e.g.

./src/
- lib/
- lib/routing
- lib/routing/index.tsx

./src/
- sections/
- sections/main/
- sections/main/main.tsx {current gutenboard.tsx}
- sections/main/index.tsx {split from controller.tsx}
- sections/create-site/
- sections/create-site/main.tsx {current create-site.tsx}
- sections/create-site/index.tsx {split from controller.tsx}

Happy to move these if we agree (probably do all in a separate PR I guess).

@sirreal sirreal force-pushed the add/gutenboarding branch from c2578c6 to ff6c9a4 Compare October 8, 2019 00:57
@simison simison force-pushed the add/gutenboarding branch from c8b7e29 to 554d4d1 Compare October 9, 2019 07:47
@simison simison force-pushed the add/gutenboarding-header branch from f0e1758 to 81d2cff Compare October 14, 2019 11:25
@matticbot
Copy link
Contributor

matticbot commented Oct 14, 2019

Here is how your PR affects size of JS and CSS bundles shipped to the user's browser:

Sections (~196 bytes added 📈 [gzipped])

name           parsed_size           gzip_size
gutenboarding       +753 B  (+0.0%)     +196 B  (+0.0%)

Sections contain code specific for a given set of routes. Is downloaded and parsed only when a particular route is navigated to.

Legend

What is parsed and gzip size?

Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory.
Gzip Size: Compressed size of the JS and CSS files. This much data needs to be downloaded over network.

Generated by performance advisor bot at iscalypsofastyet.com.

@sirreal sirreal force-pushed the add/gutenboarding branch 2 times, most recently from 05669f6 to 58dbb2c Compare October 14, 2019 15:36
@sirreal sirreal changed the base branch from add/gutenboarding to master October 15, 2019 06:52
@simison simison added [Goal] Gutenberg Working towards full integration with Gutenberg [Feature Group] Signup & Site Onboarding Tools for user registration and onboarding new users to the site. labels Oct 15, 2019
@sirreal sirreal force-pushed the add/gutenboarding-header branch from 81d2cff to 4b22b71 Compare October 15, 2019 08:43
@sirreal
Copy link
Member

sirreal commented Oct 15, 2019

Rebased and targeted to master.

@simison
Copy link
Member Author

simison commented Oct 15, 2019

All Gutenberg core styles here should be imported from possible future @wordpress/base-styles package (WordPress/gutenberg#17883) instead of copying them over.

@ockham
Copy link
Contributor

ockham commented Oct 21, 2019

With paObgF-BE-p2 in mind, what about replicating edit-post's directory structure more closely? I.e. use a components/ subfolder for the sidebar etc? (Upstream's edit-widgets also does that -- hoping to provide some amount of consistency should we ever converge with core's FSE.)

@simison simison force-pushed the add/gutenboarding-header branch from 4b22b71 to a050910 Compare October 21, 2019 07:33
@simison simison changed the title [WIP] Add gutenboarding header Gutenboarding: add header Oct 21, 2019
@simison
Copy link
Member Author

simison commented Oct 21, 2019

Valid points about components folder @ockham & @chriskmnds! Updated in a050910

@simison simison marked this pull request as ready for review October 21, 2019 08:15
@simison simison requested a review from a team as a code owner October 21, 2019 08:15
@simison simison added [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. and removed [Status] In Progress labels Oct 21, 2019
@simison simison requested a review from a team October 21, 2019 08:16
Copy link
Contributor

@ockham ockham left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM; one minor note.

(I didn't review the styling closely since it seems to be mostly copied from Gutenberg.)

@simison simison merged commit ca6835f into master Oct 21, 2019
@simison simison deleted the add/gutenboarding-header branch October 21, 2019 09:29
@matticbot matticbot removed the [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. label Oct 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature Group] Signup & Site Onboarding Tools for user registration and onboarding new users to the site. [Goal] Gutenberg Working towards full integration with Gutenberg
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants