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

Move duotone palette to the bottom of global styles gradients #37253

Merged
merged 1 commit into from
Dec 13, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -53,18 +53,6 @@ export default function GradientPalettePanel( { name } ) {
className="edit-site-global-styles-gradient-palette-panel"
spacing={ 10 }
>
<div>
<Heading className="edit-site-global-styles-gradient-palette-panel__duotone-heading">
{ __( 'Duotone' ) }
</Heading>
<DuotonePicker
duotonePalette={ duotonePalette }
disableCustomDuotone={ true }
disableCustomColors={ true }
clearable={ false }
onChange={ noop }
/>
</div>
{ !! themeGradients && !! themeGradients.length && (
<PaletteEdit
canReset={ themeGradients !== baseThemeGradients }
Expand Down Expand Up @@ -94,6 +82,18 @@ export default function GradientPalettePanel( { name } ) {
) }
slugPrefix="custom-"
/>
<div>
<Heading className="edit-site-global-styles-gradient-palette-panel__duotone-heading">
Copy link
Contributor

Choose a reason for hiding this comment

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

The Subtitle component of Global Styles was written to avoid defining the styles and classes for each heading, we should probably just use it here and for the vertical spacing we should use Stack instead of custom margins

Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, saw that too

Copy link
Member

Choose a reason for hiding this comment

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

Hi @youknowriad, the subtitle component does not provide the same visual we want here according to the mockups:

Subtitle:
image

What we have:
image

Should we use the subtitle for all the palette titles even though there is a small difference when compared to the mockups?

Copy link
Contributor

Choose a reason for hiding this comment

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

@jorgefilipecosta Updating makes sense to me, the important thing is that be consistent across all global styles panels.

Copy link
Member Author

Choose a reason for hiding this comment

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

We should fix the component, it should render smaller

{ __( 'Duotone' ) }
</Heading>
<DuotonePicker
duotonePalette={ duotonePalette }
disableCustomDuotone={ true }
disableCustomColors={ true }
clearable={ false }
onChange={ noop }
/>
</div>
</VStack>
);
}