newspack-components 2.2.1 → 3.0.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/babel.config.js +25 -0
- package/copy-styles.js +2 -10
- package/dist/{cjs/accordion → accordion}/index.js +17 -13
- package/dist/{cjs/accordion → accordion}/style.scss +7 -3
- package/dist/{cjs/action-card → action-card}/index.js +39 -43
- package/dist/{esm/action-card → action-card}/style.scss +9 -9
- package/dist/{cjs/autocomplete-tokenfield → autocomplete-tokenfield}/index.js +67 -29
- package/dist/{esm/autocomplete-tokenfield → autocomplete-tokenfield}/style.scss +14 -8
- package/dist/{cjs/autocomplete-with-suggestions → autocomplete-with-suggestions}/index.js +61 -73
- package/dist/{esm/autocomplete-with-suggestions → autocomplete-with-suggestions}/style.scss +9 -17
- package/dist/button/index.js +51 -0
- package/{src/button/index.js → dist/button/index.tsx} +12 -5
- package/dist/{cjs/button → button}/style.scss +1 -1
- package/dist/{cjs/button-card → button-card}/index.js +9 -10
- package/dist/{cjs/button-card → button-card}/style.scss +19 -13
- package/dist/{cjs/card → card}/index.js +4 -5
- package/dist/{esm/card → card}/style.scss +1 -1
- package/dist/{cjs/category-autocomplete → category-autocomplete}/index.js +51 -53
- package/dist/{esm/category-autocomplete → category-autocomplete}/style.scss +2 -2
- package/dist/{cjs/color-picker → color-picker}/index.js +14 -16
- package/dist/{cjs/color-picker → color-picker}/style.scss +3 -3
- package/dist/consts.js +7 -0
- package/dist/{cjs/custom-select-control → custom-select-control}/index.js +4 -5
- package/dist/{cjs/custom-select-control → custom-select-control}/style.scss +11 -10
- package/dist/{cjs/date-range-picker → date-range-picker}/index.js +9 -11
- package/dist/{cjs/date-range-picker → date-range-picker}/style.scss +6 -6
- package/dist/{cjs/footer → footer}/index.js +33 -36
- package/dist/{cjs/footer → footer}/style.scss +1 -1
- package/dist/{cjs/form-token-field → form-token-field}/index.js +6 -7
- package/dist/{esm/form-token-field → form-token-field}/style.scss +1 -1
- package/dist/{cjs/global-notices → global-notices}/index.js +4 -5
- package/dist/grid/index.js +44 -0
- package/dist/grid/index.tsx +34 -0
- package/dist/{cjs/grid → grid}/style.scss +9 -9
- package/dist/{cjs/handoff → handoff}/index.js +73 -71
- package/dist/{cjs/handoff-message → handoff-message}/index.js +5 -3
- package/dist/hooks/index.js +29 -0
- package/{src/hooks/index.js → dist/hooks/index.ts} +1 -1
- package/dist/{cjs/hooks → hooks}/useObjectState.js +2 -3
- package/dist/{cjs/hooks → hooks}/useObjectState.test.js +9 -9
- package/dist/{cjs/hooks → hooks}/useOnClickOutside.js +1 -2
- package/dist/hooks/usePrompt.js +47 -0
- package/{src/hooks/usePrompt.js → dist/hooks/usePrompt.ts} +4 -8
- package/dist/image-upload/index.js +148 -0
- package/dist/{cjs/image-upload → image-upload}/index.test.js +13 -6
- package/dist/{esm/image-upload → image-upload}/style.scss +5 -5
- package/dist/{cjs/index.js → index.js} +1 -1
- package/dist/{cjs/info-button → info-button}/index.js +6 -7
- package/dist/{cjs/modal → modal}/index.js +4 -5
- package/dist/{esm/modal → modal}/style.scss +5 -5
- package/dist/{cjs/newspack-icon → newspack-icon}/index.js +5 -6
- package/dist/{cjs/newspack-icon → newspack-icon}/style.scss +1 -1
- package/dist/{cjs/newspack-logo → newspack-logo}/index.js +5 -6
- package/dist/{cjs/newspack-logo → newspack-logo}/style.scss +1 -1
- package/dist/{cjs/notice → notice}/index.js +12 -10
- package/dist/{cjs/notice → notice}/style.scss +11 -11
- package/dist/patrons-logo/index.js +77 -0
- package/dist/plugin-installer/index.js +297 -0
- package/dist/{cjs/plugin-installer → plugin-installer}/style.scss +1 -1
- package/dist/{cjs/plugin-settings → plugin-settings}/SettingsSection.js +13 -13
- package/dist/plugin-settings/index.js +228 -0
- package/dist/{cjs/plugin-settings → plugin-settings}/style.scss +1 -1
- package/dist/plugin-toggle/README.md +53 -0
- package/dist/plugin-toggle/index.js +222 -0
- package/dist/{esm/plugin-toggle → plugin-toggle}/style.scss +1 -1
- package/dist/{cjs/popover → popover}/index.js +4 -5
- package/dist/{cjs/popover → popover}/style.scss +7 -7
- package/dist/{cjs/position-control → position-control}/index.js +33 -32
- package/dist/{cjs/position-control → position-control}/style.scss +8 -8
- package/dist/{cjs/progress-bar → progress-bar}/index.js +9 -10
- package/dist/{cjs/progress-bar → progress-bar}/index.test.js +16 -16
- package/dist/{cjs/progress-bar → progress-bar}/style.scss +2 -2
- package/dist/proxied-imports/router.js +15 -0
- package/dist/{cjs/radio-control → radio-control}/index.js +4 -5
- package/dist/{cjs/radio-control → radio-control}/style.scss +3 -3
- package/dist/{cjs/section-header → section-header}/index.js +20 -21
- package/dist/{esm/section-header → section-header}/style.scss +5 -1
- package/dist/{cjs/select-control → select-control}/ButtonGroupControl.js +17 -19
- package/dist/{cjs/select-control → select-control}/GroupedSelectControl.js +32 -35
- package/dist/{cjs/select-control → select-control}/index.js +7 -8
- package/dist/{cjs/select-control → select-control}/style.scss +4 -4
- package/dist/settings/MinMaxSetting.js +60 -0
- package/dist/{cjs/settings → settings}/SettingsCard.js +14 -16
- package/dist/settings/SettingsSection.js +33 -0
- package/dist/{cjs/settings → settings}/index.js +3 -4
- package/dist/{cjs/settings → settings}/style.scss +15 -2
- package/dist/sortable-newsletter-list-control/index.js +135 -0
- package/dist/sortable-newsletter-list-control/style.scss +45 -0
- package/dist/{cjs/steps-list → steps-list}/index.js +5 -6
- package/dist/{esm/steps-list → steps-list}/style.scss +2 -2
- package/dist/{cjs/steps-list-item → steps-list-item}/index.js +6 -7
- package/dist/{cjs/steps-list-item → steps-list-item}/style.scss +5 -5
- package/dist/{cjs/style-card → style-card}/index.js +21 -19
- package/dist/{esm/style-card → style-card}/style.scss +4 -4
- package/dist/{esm/style.scss → style.scss} +14 -2
- package/dist/{cjs/tabbed-navigation → tabbed-navigation}/index.js +16 -19
- package/dist/{cjs/tabbed-navigation → tabbed-navigation}/style.scss +4 -4
- package/dist/text-control/index.js +76 -0
- package/dist/text-control/index.tsx +71 -0
- package/dist/utils/index.js +36 -0
- package/dist/{cjs/waiting → waiting}/index.js +4 -5
- package/dist/web-preview/index.js +191 -0
- package/dist/{cjs/web-preview → web-preview}/style.scss +5 -5
- package/dist/with-wizard/index.js +328 -0
- package/dist/{esm/with-wizard → with-wizard}/style.scss +44 -22
- package/dist/{cjs/with-wizard-screen → with-wizard-screen}/index.js +40 -43
- package/dist/{esm/with-wizard-screen → with-wizard-screen}/style.scss +7 -7
- package/dist/{cjs/wizard → wizard}/components/WizardError.js +16 -17
- package/dist/{cjs/wizard → wizard}/index.js +44 -46
- package/dist/{cjs/wizard → wizard}/store/index.js +37 -38
- package/dist/{cjs/wizard → wizard}/store/utils.js +1 -4
- package/package.json +16 -14
- package/shared/scss/_mixins.scss +2 -2
- package/src/accordion/index.js +4 -1
- package/src/accordion/style.scss +7 -3
- package/src/action-card/style.scss +9 -9
- package/src/autocomplete-tokenfield/index.js +48 -15
- package/src/autocomplete-tokenfield/style.scss +14 -8
- package/src/autocomplete-with-suggestions/index.js +59 -62
- package/src/autocomplete-with-suggestions/style.scss +9 -17
- package/src/button/index.tsx +48 -0
- package/src/button/style.scss +1 -1
- package/src/button-card/style.scss +19 -13
- package/src/card/style.scss +1 -1
- package/src/category-autocomplete/style.scss +2 -2
- package/src/color-picker/style.scss +3 -3
- package/src/consts.js +0 -2
- package/src/custom-select-control/style.scss +11 -10
- package/src/date-range-picker/style.scss +6 -6
- package/src/footer/index.js +7 -7
- package/src/footer/style.scss +1 -1
- package/src/form-token-field/style.scss +1 -1
- package/src/grid/index.tsx +34 -0
- package/src/grid/style.scss +9 -9
- package/src/handoff/index.js +7 -6
- package/src/handoff-message/index.js +3 -1
- package/src/hooks/index.ts +15 -0
- package/src/hooks/usePrompt.ts +46 -0
- package/src/image-upload/index.js +5 -5
- package/src/image-upload/index.test.js +6 -1
- package/src/image-upload/style.scss +5 -5
- package/src/modal/style.scss +5 -5
- package/src/newspack-icon/style.scss +1 -1
- package/src/newspack-logo/style.scss +1 -1
- package/src/notice/index.js +1 -1
- package/src/notice/style.scss +11 -11
- package/src/patrons-logo/index.js +4 -1
- package/src/plugin-installer/index.js +7 -7
- package/src/plugin-installer/style.scss +1 -1
- package/src/plugin-settings/index.js +1 -1
- package/src/plugin-settings/style.scss +1 -1
- package/src/plugin-toggle/index.js +13 -12
- package/src/plugin-toggle/style.scss +1 -1
- package/src/popover/style.scss +7 -7
- package/src/position-control/index.js +63 -64
- package/src/position-control/style.scss +8 -8
- package/src/progress-bar/style.scss +2 -2
- package/src/radio-control/style.scss +3 -3
- package/src/section-header/index.js +3 -3
- package/src/section-header/style.scss +5 -1
- package/src/select-control/GroupedSelectControl.js +1 -1
- package/src/select-control/style.scss +4 -4
- package/src/settings/MinMaxSetting.js +8 -6
- package/src/settings/style.scss +15 -2
- package/src/sortable-newsletter-list-control/index.js +137 -0
- package/src/sortable-newsletter-list-control/style.scss +45 -0
- package/src/steps-list/style.scss +2 -2
- package/src/steps-list-item/style.scss +5 -5
- package/src/style-card/index.js +11 -5
- package/src/style-card/style.scss +4 -4
- package/src/style.scss +14 -2
- package/src/tabbed-navigation/style.scss +4 -4
- package/src/text-control/index.tsx +65 -0
- package/src/web-preview/index.js +6 -6
- package/src/web-preview/style.scss +5 -5
- package/src/with-wizard/index.js +4 -4
- package/src/with-wizard/style.scss +44 -22
- package/src/with-wizard-screen/index.js +1 -1
- package/src/with-wizard-screen/style.scss +7 -7
- package/src/wizard/components/WizardError.js +1 -1
- package/src/wizard/index.js +3 -3
- package/src/wizard/store/index.js +9 -2
- package/dist/cjs/action-card/style.scss +0 -483
- package/dist/cjs/autocomplete-tokenfield/style.scss +0 -43
- package/dist/cjs/autocomplete-with-suggestions/style.scss +0 -171
- package/dist/cjs/button/index.js +0 -57
- package/dist/cjs/card/style.scss +0 -168
- package/dist/cjs/category-autocomplete/style.scss +0 -34
- package/dist/cjs/consts.js +0 -12
- package/dist/cjs/form-token-field/style.scss +0 -37
- package/dist/cjs/grid/index.js +0 -54
- package/dist/cjs/hooks/index.js +0 -26
- package/dist/cjs/hooks/usePrompt.js +0 -52
- package/dist/cjs/image-upload/index.js +0 -144
- package/dist/cjs/image-upload/style.scss +0 -103
- package/dist/cjs/modal/style.scss +0 -56
- package/dist/cjs/patrons-logo/index.js +0 -82
- package/dist/cjs/plugin-installer/index.js +0 -299
- package/dist/cjs/plugin-settings/index.js +0 -222
- package/dist/cjs/plugin-toggle/index.js +0 -222
- package/dist/cjs/plugin-toggle/style.scss +0 -20
- package/dist/cjs/proxied-imports/router.js +0 -15
- package/dist/cjs/section-header/style.scss +0 -41
- package/dist/cjs/settings/MinMaxSetting.js +0 -57
- package/dist/cjs/settings/SettingsSection.js +0 -37
- package/dist/cjs/steps-list/style.scss +0 -11
- package/dist/cjs/style-card/style.scss +0 -94
- package/dist/cjs/style.scss +0 -43
- package/dist/cjs/text-control/index.js +0 -71
- package/dist/cjs/utils/index.js +0 -40
- package/dist/cjs/web-preview/index.js +0 -189
- package/dist/cjs/with-wizard/index.js +0 -318
- package/dist/cjs/with-wizard/style.scss +0 -260
- package/dist/cjs/with-wizard-screen/style.scss +0 -160
- package/dist/esm/accordion/index.js +0 -38
- package/dist/esm/accordion/style.scss +0 -27
- package/dist/esm/action-card/index.js +0 -222
- package/dist/esm/autocomplete-tokenfield/index.js +0 -223
- package/dist/esm/autocomplete-with-suggestions/index.js +0 -289
- package/dist/esm/button/index.js +0 -48
- package/dist/esm/button/style.scss +0 -11
- package/dist/esm/button-card/index.js +0 -65
- package/dist/esm/button-card/style.scss +0 -174
- package/dist/esm/card/index.js +0 -43
- package/dist/esm/category-autocomplete/index.js +0 -185
- package/dist/esm/color-picker/index.js +0 -61
- package/dist/esm/color-picker/style.scss +0 -37
- package/dist/esm/consts.js +0 -3
- package/dist/esm/custom-select-control/index.js +0 -37
- package/dist/esm/custom-select-control/style.scss +0 -92
- package/dist/esm/date-range-picker/index.js +0 -32
- package/dist/esm/date-range-picker/style.scss +0 -148
- package/dist/esm/footer/index.js +0 -105
- package/dist/esm/footer/style.scss +0 -82
- package/dist/esm/form-token-field/index.js +0 -50
- package/dist/esm/global-notices/index.js +0 -30
- package/dist/esm/grid/index.js +0 -45
- package/dist/esm/grid/style.scss +0 -166
- package/dist/esm/handoff/index.js +0 -177
- package/dist/esm/handoff-message/index.js +0 -45
- package/dist/esm/hooks/index.js +0 -17
- package/dist/esm/hooks/useObjectState.js +0 -31
- package/dist/esm/hooks/useObjectState.test.js +0 -83
- package/dist/esm/hooks/useOnClickOutside.js +0 -31
- package/dist/esm/hooks/usePrompt.js +0 -43
- package/dist/esm/image-upload/index.js +0 -141
- package/dist/esm/image-upload/index.test.js +0 -28
- package/dist/esm/index.js +0 -47
- package/dist/esm/info-button/index.js +0 -42
- package/dist/esm/info-button/style.scss +0 -18
- package/dist/esm/modal/index.js +0 -39
- package/dist/esm/newspack-icon/index.js +0 -50
- package/dist/esm/newspack-icon/style.scss +0 -26
- package/dist/esm/newspack-logo/index.js +0 -46
- package/dist/esm/newspack-logo/style.scss +0 -30
- package/dist/esm/notice/index.js +0 -67
- package/dist/esm/notice/style.scss +0 -111
- package/dist/esm/patrons-logo/index.js +0 -76
- package/dist/esm/plugin-installer/index.js +0 -295
- package/dist/esm/plugin-installer/style.scss +0 -72
- package/dist/esm/plugin-settings/SettingsSection.js +0 -136
- package/dist/esm/plugin-settings/index.js +0 -217
- package/dist/esm/plugin-settings/style.scss +0 -7
- package/dist/esm/plugin-toggle/index.js +0 -217
- package/dist/esm/popover/index.js +0 -41
- package/dist/esm/popover/style.scss +0 -161
- package/dist/esm/position-control/index.js +0 -109
- package/dist/esm/position-control/style.scss +0 -66
- package/dist/esm/progress-bar/index.js +0 -69
- package/dist/esm/progress-bar/index.test.js +0 -110
- package/dist/esm/progress-bar/style.scss +0 -42
- package/dist/esm/proxied-imports/router.js +0 -8
- package/dist/esm/radio-control/index.js +0 -37
- package/dist/esm/radio-control/style.scss +0 -92
- package/dist/esm/section-header/index.js +0 -68
- package/dist/esm/select-control/ButtonGroupControl.js +0 -54
- package/dist/esm/select-control/GroupedSelectControl.js +0 -84
- package/dist/esm/select-control/index.js +0 -51
- package/dist/esm/select-control/style.scss +0 -108
- package/dist/esm/settings/MinMaxSetting.js +0 -53
- package/dist/esm/settings/SettingsCard.js +0 -39
- package/dist/esm/settings/SettingsSection.js +0 -30
- package/dist/esm/settings/index.js +0 -9
- package/dist/esm/settings/style.scss +0 -106
- package/dist/esm/steps-list/index.js +0 -43
- package/dist/esm/steps-list-item/index.js +0 -48
- package/dist/esm/steps-list-item/style.scss +0 -47
- package/dist/esm/style-card/index.js +0 -76
- package/dist/esm/tabbed-navigation/index.js +0 -56
- package/dist/esm/tabbed-navigation/style.scss +0 -86
- package/dist/esm/text-control/index.js +0 -66
- package/dist/esm/text-control/style.scss +0 -32
- package/dist/esm/utils/index.js +0 -32
- package/dist/esm/waiting/index.js +0 -44
- package/dist/esm/waiting/style.scss +0 -27
- package/dist/esm/web-preview/index.js +0 -184
- package/dist/esm/web-preview/style.scss +0 -155
- package/dist/esm/with-wizard/index.js +0 -313
- package/dist/esm/with-wizard-screen/index.js +0 -116
- package/dist/esm/wizard/components/WizardError.js +0 -69
- package/dist/esm/wizard/index.js +0 -126
- package/dist/esm/wizard/store/index.js +0 -155
- package/dist/esm/wizard/store/utils.js +0 -17
- package/src/grid/index.js +0 -44
- package/src/text-control/index.js +0 -56
- /package/dist/{cjs/info-button → info-button}/style.scss +0 -0
- /package/dist/{cjs/text-control → text-control}/style.scss +0 -0
- /package/dist/{cjs/waiting → waiting}/style.scss +0 -0
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Button
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* WordPress dependencies.
|
|
7
|
+
*/
|
|
8
|
+
import { Button as BaseComponent } from '@wordpress/components';
|
|
9
|
+
import { useState } from '@wordpress/element';
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* Internal dependencies
|
|
13
|
+
*/
|
|
14
|
+
import Router from '../proxied-imports/router';
|
|
15
|
+
import './style.scss';
|
|
16
|
+
|
|
17
|
+
const { useHistory } = Router;
|
|
18
|
+
|
|
19
|
+
type OriginalButtonProps = typeof BaseComponent.defaultProps;
|
|
20
|
+
type Props = OriginalButtonProps & {
|
|
21
|
+
href?: string;
|
|
22
|
+
onClick?: () => void;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
const Button = ( { href, onClick, ...otherProps }: Props ) => {
|
|
26
|
+
const history = useHistory();
|
|
27
|
+
const [ isAwaitingOnClick, setIsAwaitingOnClick ] = useState( false );
|
|
28
|
+
|
|
29
|
+
// If both onClick and href are present, await the onClick action an then redirect.
|
|
30
|
+
if ( href && onClick ) {
|
|
31
|
+
( otherProps as Props ).onClick = async () => {
|
|
32
|
+
setIsAwaitingOnClick( true );
|
|
33
|
+
await onClick();
|
|
34
|
+
setIsAwaitingOnClick( false );
|
|
35
|
+
history.push( ( href || '' ).replace( '#', '' ) );
|
|
36
|
+
};
|
|
37
|
+
} else {
|
|
38
|
+
( otherProps as Props ).href = href;
|
|
39
|
+
( otherProps as Props ).onClick = onClick;
|
|
40
|
+
}
|
|
41
|
+
if ( isAwaitingOnClick ) {
|
|
42
|
+
otherProps.disabled = true;
|
|
43
|
+
}
|
|
44
|
+
// @ts-ignore - @wordpress/components' Button can only have either href or onClick, not both.
|
|
45
|
+
return <BaseComponent { ...otherProps } />;
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
export default Button;
|
package/src/button/style.scss
CHANGED
|
@@ -2,40 +2,44 @@
|
|
|
2
2
|
* Button Card
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
-
@use
|
|
5
|
+
@use "~@wordpress/base-styles/colors" as wp-colors;
|
|
6
6
|
|
|
7
7
|
.newspack-button-card {
|
|
8
8
|
background: white;
|
|
9
9
|
border-radius: 2px;
|
|
10
10
|
border: 1px solid wp-colors.$gray-300;
|
|
11
|
-
box-shadow: inset 0 0 0 var(
|
|
11
|
+
box-shadow: inset 0 0 0 var(--wp-admin-border-width-focus) transparent;
|
|
12
12
|
cursor: pointer;
|
|
13
13
|
display: block;
|
|
14
14
|
margin: 32px 0;
|
|
15
15
|
padding: 32px;
|
|
16
16
|
position: relative;
|
|
17
17
|
text-decoration: none;
|
|
18
|
-
transition:
|
|
18
|
+
transition:
|
|
19
|
+
background-color 125ms ease-in-out,
|
|
20
|
+
border-color 125ms ease-in-out,
|
|
19
21
|
box-shadow 125ms ease-in-out;
|
|
20
22
|
|
|
21
23
|
&:focus,
|
|
22
24
|
&.is-pressed {
|
|
23
25
|
background: white;
|
|
24
|
-
border-color: var(
|
|
25
|
-
box-shadow: inset 0 0 0 1px var(
|
|
26
|
+
border-color: var(--wp-admin-theme-color);
|
|
27
|
+
box-shadow: inset 0 0 0 1px var(--wp-admin-theme-color) !important;
|
|
26
28
|
outline: none !important;
|
|
27
29
|
z-index: 1;
|
|
28
30
|
}
|
|
29
31
|
|
|
30
32
|
&.is-pressed:focus-visible {
|
|
31
|
-
box-shadow:
|
|
32
|
-
0 0 0
|
|
33
|
+
box-shadow:
|
|
34
|
+
inset 0 0 0 1px var(--wp-admin-theme-color),
|
|
35
|
+
0 0 0 1px white,
|
|
36
|
+
0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color) !important;
|
|
33
37
|
}
|
|
34
38
|
|
|
35
39
|
&:active,
|
|
36
40
|
&:hover {
|
|
37
|
-
border-color: var(
|
|
38
|
-
color: var(
|
|
41
|
+
border-color: var(--wp-admin-theme-color);
|
|
42
|
+
color: var(--wp-admin-theme-color);
|
|
39
43
|
text-decoration: none;
|
|
40
44
|
z-index: 1;
|
|
41
45
|
|
|
@@ -63,7 +67,7 @@
|
|
|
63
67
|
&.grouped {
|
|
64
68
|
border-radius: 0;
|
|
65
69
|
|
|
66
|
-
& + &:not(
|
|
70
|
+
& + &:not(.br--top) {
|
|
67
71
|
margin-top: -33px;
|
|
68
72
|
}
|
|
69
73
|
|
|
@@ -95,7 +99,7 @@
|
|
|
95
99
|
}
|
|
96
100
|
|
|
97
101
|
svg {
|
|
98
|
-
fill: var(
|
|
102
|
+
fill: var(--wp-admin-theme-color);
|
|
99
103
|
transition: fill 125ms ease-in-out;
|
|
100
104
|
}
|
|
101
105
|
}
|
|
@@ -161,8 +165,10 @@
|
|
|
161
165
|
}
|
|
162
166
|
|
|
163
167
|
&.is-pressed:focus-visible {
|
|
164
|
-
box-shadow:
|
|
165
|
-
0 0 0
|
|
168
|
+
box-shadow:
|
|
169
|
+
inset 0 0 0 1px wp-colors.$alert-red,
|
|
170
|
+
0 0 0 1px white,
|
|
171
|
+
0 0 0 var(--wp-admin-border-width-focus) wp-colors.$alert-red !important;
|
|
166
172
|
}
|
|
167
173
|
|
|
168
174
|
&:active,
|
package/src/card/style.scss
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
}
|
|
11
11
|
|
|
12
12
|
&__expander {
|
|
13
|
-
box-shadow: inset 0 0 0 1px rgb(
|
|
13
|
+
box-shadow: inset 0 0 0 1px rgb(0 0 0 / 20%);
|
|
14
14
|
border-radius: 2px;
|
|
15
15
|
height: 64px;
|
|
16
16
|
padding: 12px;
|
|
@@ -18,14 +18,14 @@
|
|
|
18
18
|
text-transform: uppercase;
|
|
19
19
|
|
|
20
20
|
&:focus-visible {
|
|
21
|
-
box-shadow: 0 0 0 var(
|
|
21
|
+
box-shadow: 0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);
|
|
22
22
|
border-color: white;
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
&__main {
|
|
27
27
|
background: white;
|
|
28
|
-
box-shadow: 0 0 8px 4px rgba(
|
|
28
|
+
box-shadow: 0 0 8px 4px rgba(black, 0.08);
|
|
29
29
|
margin: 12px 0;
|
|
30
30
|
position: absolute;
|
|
31
31
|
z-index: 2;
|
package/src/consts.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Custom Select Control
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
-
@use
|
|
5
|
+
@use "~@wordpress/base-styles/colors" as wp-colors;
|
|
6
6
|
|
|
7
7
|
.newspack-custom-select-control {
|
|
8
8
|
label {
|
|
@@ -22,13 +22,13 @@
|
|
|
22
22
|
&:active,
|
|
23
23
|
&:focus,
|
|
24
24
|
&:hover,
|
|
25
|
-
&[aria-expanded=
|
|
25
|
+
&[aria-expanded="true"] {
|
|
26
26
|
color: wp-colors.$gray-900;
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
&:focus {
|
|
30
|
-
border-color: var(
|
|
31
|
-
box-shadow: inset 0 0 0 1px var(
|
|
30
|
+
border-color: var(--wp-admin-theme-color);
|
|
31
|
+
box-shadow: inset 0 0 0 1px var(--wp-admin-theme-color);
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
&-icon {
|
|
@@ -36,15 +36,15 @@
|
|
|
36
36
|
width: 18px;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
&[aria-expanded=
|
|
40
|
-
transform: rotate(
|
|
39
|
+
&[aria-expanded="true"] svg {
|
|
40
|
+
transform: rotate(180deg);
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
.components-custom-select-control__menu {
|
|
45
45
|
border-color: wp-colors.$gray-700;
|
|
46
46
|
border-radius: 2px;
|
|
47
|
-
box-shadow: 0 4px 8px rgba(
|
|
47
|
+
box-shadow: 0 4px 8px rgba(black, 0.08);
|
|
48
48
|
margin: 8px 0 0;
|
|
49
49
|
min-width: 222px;
|
|
50
50
|
}
|
|
@@ -72,16 +72,17 @@
|
|
|
72
72
|
|
|
73
73
|
&.is-highlighted {
|
|
74
74
|
background: white;
|
|
75
|
-
color: var(
|
|
75
|
+
color: var(--wp-admin-theme-color);
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
&.is-selected {
|
|
79
79
|
margin-left: 0;
|
|
80
80
|
|
|
81
81
|
&::before {
|
|
82
|
-
background:
|
|
82
|
+
background:
|
|
83
|
+
url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgd2lkdGg9IjI0IiBoZWlnaHQ9IjI0Ij48cGF0aCBkPSJNMTguMyA1LjZMOS45IDE2LjlsLTQuNi0zLjQtLjkgMS4yIDUuOCA0LjMgOS4zLTEyLjZ6IiBmaWxsPSIjMzM2NmZmIj48L3BhdGg+PC9zdmc+Cg==")
|
|
83
84
|
0 0 no-repeat;
|
|
84
|
-
content:
|
|
85
|
+
content: "";
|
|
85
86
|
display: block;
|
|
86
87
|
height: 24px;
|
|
87
88
|
margin: 0 4px 0 0;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
@use
|
|
2
|
-
@use
|
|
1
|
+
@use "../../../shared/scss/colors";
|
|
2
|
+
@use "~@wordpress/base-styles/colors" as wp-colors;
|
|
3
3
|
|
|
4
4
|
.DateRangePicker {
|
|
5
5
|
margin: 32px 0;
|
|
@@ -15,20 +15,20 @@
|
|
|
15
15
|
width: 36px;
|
|
16
16
|
|
|
17
17
|
&--previous {
|
|
18
|
-
background-image: url(
|
|
18
|
+
background-image: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"%3E%3Cpath d="M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z" fill="%231e1e1e"/%3E%3C/svg%3E');
|
|
19
19
|
left: 0;
|
|
20
20
|
|
|
21
21
|
&:hover {
|
|
22
|
-
background-image: url(
|
|
22
|
+
background-image: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"%3E%3Cpath d="M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z" fill="%2336f"/%3E%3C/svg%3E');
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
&--next {
|
|
27
|
-
background-image: url(
|
|
27
|
+
background-image: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"%3E%3Cpath d="M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z" fill="%231e1e1e"/%3E%3C/svg%3E');
|
|
28
28
|
right: 0;
|
|
29
29
|
|
|
30
30
|
&:hover {
|
|
31
|
-
background-image: url(
|
|
31
|
+
background-image: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"%3E%3Cpath d="M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z" fill="%2336f"/%3E%3C/svg%3E');
|
|
32
32
|
}
|
|
33
33
|
}
|
|
34
34
|
|
package/src/footer/index.js
CHANGED
|
@@ -32,43 +32,43 @@ const Footer = ( { simple } ) => {
|
|
|
32
32
|
external: true,
|
|
33
33
|
},
|
|
34
34
|
{
|
|
35
|
-
label: __( 'About', 'newspack' ),
|
|
35
|
+
label: __( 'About', 'newspack-plugin' ),
|
|
36
36
|
url: 'https://newspack.com/',
|
|
37
37
|
external: true,
|
|
38
38
|
},
|
|
39
39
|
{
|
|
40
|
-
label: __( 'Documentation', 'newspack' ),
|
|
40
|
+
label: __( 'Documentation', 'newspack-plugin' ),
|
|
41
41
|
url: support,
|
|
42
42
|
external: true,
|
|
43
43
|
},
|
|
44
44
|
];
|
|
45
45
|
if ( componentsDemo ) {
|
|
46
46
|
footerElements.push( {
|
|
47
|
-
label: __( 'Components Demo', 'newspack' ),
|
|
47
|
+
label: __( 'Components Demo', 'newspack-plugin' ),
|
|
48
48
|
url: componentsDemo,
|
|
49
49
|
} );
|
|
50
50
|
}
|
|
51
51
|
if ( setupWizard ) {
|
|
52
52
|
footerElements.push( {
|
|
53
|
-
label: __( 'Setup Wizard', 'newspack' ),
|
|
53
|
+
label: __( 'Setup Wizard', 'newspack-plugin' ),
|
|
54
54
|
url: setupWizard,
|
|
55
55
|
} );
|
|
56
56
|
}
|
|
57
57
|
if ( resetUrl ) {
|
|
58
58
|
footerElements.push( {
|
|
59
|
-
label: __( 'Reset Newspack', 'newspack' ),
|
|
59
|
+
label: __( 'Reset Newspack', 'newspack-plugin' ),
|
|
60
60
|
url: resetUrl,
|
|
61
61
|
} );
|
|
62
62
|
}
|
|
63
63
|
if ( removeStarterContent ) {
|
|
64
64
|
footerElements.push( {
|
|
65
|
-
label: __( 'Remove Starter Content', 'newspack' ),
|
|
65
|
+
label: __( 'Remove Starter Content', 'newspack-plugin' ),
|
|
66
66
|
url: removeStarterContent,
|
|
67
67
|
} );
|
|
68
68
|
}
|
|
69
69
|
if ( supportEmail ) {
|
|
70
70
|
footerElements.push( {
|
|
71
|
-
label: __( 'Contact Support', 'newspack' ),
|
|
71
|
+
label: __( 'Contact Support', 'newspack-plugin' ),
|
|
72
72
|
url: `mailto:${ supportEmail }`,
|
|
73
73
|
} );
|
|
74
74
|
}
|
package/src/footer/style.scss
CHANGED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Grid
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Internal dependencies
|
|
7
|
+
*/
|
|
8
|
+
import './style.scss';
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* External dependencies
|
|
12
|
+
*/
|
|
13
|
+
import classnames from 'classnames';
|
|
14
|
+
|
|
15
|
+
const Grid = ( {
|
|
16
|
+
className = '',
|
|
17
|
+
columns = 2,
|
|
18
|
+
gutter = 32,
|
|
19
|
+
noMargin = false,
|
|
20
|
+
rowGap = 0,
|
|
21
|
+
...otherProps
|
|
22
|
+
} ) => {
|
|
23
|
+
const classes = classnames(
|
|
24
|
+
'newspack-grid',
|
|
25
|
+
noMargin && 'newspack-grid--no-margin',
|
|
26
|
+
columns && 'newspack-grid__columns-' + columns,
|
|
27
|
+
gutter && 'newspack-grid__gutter-' + gutter,
|
|
28
|
+
rowGap && 'newspack-grid__row-gap-' + rowGap,
|
|
29
|
+
className
|
|
30
|
+
);
|
|
31
|
+
return <div className={ classes } { ...otherProps } />;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
export default Grid;
|
package/src/grid/style.scss
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Grid
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
-
@use
|
|
5
|
+
@use "~@wordpress/base-styles/colors" as wp-colors;
|
|
6
6
|
|
|
7
7
|
.newspack-grid {
|
|
8
8
|
display: grid;
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
|
|
69
69
|
// Columns 6
|
|
70
70
|
&__columns-6 {
|
|
71
|
-
grid-template-columns: repeat(
|
|
71
|
+
grid-template-columns: repeat(2, 1fr);
|
|
72
72
|
}
|
|
73
73
|
|
|
74
74
|
// Media Queries - 744px
|
|
@@ -76,11 +76,11 @@
|
|
|
76
76
|
&__columns-2,
|
|
77
77
|
&__columns-3,
|
|
78
78
|
&__columns-4 {
|
|
79
|
-
grid-template-columns: repeat(
|
|
79
|
+
grid-template-columns: repeat(2, 1fr);
|
|
80
80
|
}
|
|
81
81
|
|
|
82
82
|
&__columns-6 {
|
|
83
|
-
grid-template-columns: repeat(
|
|
83
|
+
grid-template-columns: repeat(3, 1fr);
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
86
|
|
|
@@ -88,17 +88,17 @@
|
|
|
88
88
|
@media screen and ( min-width: 1128px ) {
|
|
89
89
|
// Columns 3
|
|
90
90
|
&__columns-3 {
|
|
91
|
-
grid-template-columns: repeat(
|
|
91
|
+
grid-template-columns: repeat(3, 1fr);
|
|
92
92
|
}
|
|
93
93
|
|
|
94
94
|
// Columns 4
|
|
95
95
|
&__columns-4 {
|
|
96
|
-
grid-template-columns: repeat(
|
|
96
|
+
grid-template-columns: repeat(4, 1fr);
|
|
97
97
|
}
|
|
98
98
|
|
|
99
99
|
// Columns 6
|
|
100
100
|
&__columns-6 {
|
|
101
|
-
grid-template-columns: repeat(
|
|
101
|
+
grid-template-columns: repeat(6, 1fr);
|
|
102
102
|
}
|
|
103
103
|
|
|
104
104
|
// Gutter 48
|
|
@@ -144,12 +144,12 @@
|
|
|
144
144
|
|
|
145
145
|
// Table-like
|
|
146
146
|
&__thead {
|
|
147
|
-
background: rgba(
|
|
147
|
+
background: rgba(black, 0.025);
|
|
148
148
|
border-bottom: 1px solid wp-colors.$gray-300;
|
|
149
149
|
border-top: 1px solid wp-colors.$gray-300;
|
|
150
150
|
color: wp-colors.$gray-900;
|
|
151
151
|
|
|
152
|
-
> *:not(
|
|
152
|
+
> *:not(.screen-reader-text) {
|
|
153
153
|
padding: 8px;
|
|
154
154
|
}
|
|
155
155
|
}
|
package/src/handoff/index.js
CHANGED
|
@@ -52,10 +52,11 @@ class Handoff extends Component {
|
|
|
52
52
|
textForPlugin = pluginInfo => {
|
|
53
53
|
const defaults = {
|
|
54
54
|
modalBody: null,
|
|
55
|
-
modalTitle: pluginInfo.Name && `${ __( 'Manage', 'newspack' ) } ${ pluginInfo.Name }`,
|
|
56
|
-
primaryButton:
|
|
57
|
-
|
|
58
|
-
|
|
55
|
+
modalTitle: pluginInfo.Name && `${ __( 'Manage', 'newspack-plugin' ) } ${ pluginInfo.Name }`,
|
|
56
|
+
primaryButton:
|
|
57
|
+
pluginInfo.Name && `${ __( 'Manage', 'newspack-plugin' ) } ${ pluginInfo.Name }`,
|
|
58
|
+
primaryModalButton: __( 'Manage', 'newspack-plugin' ),
|
|
59
|
+
dismissModalButton: __( 'Dismiss', 'newspack-plugin' ),
|
|
59
60
|
};
|
|
60
61
|
return assign( defaults, this.props );
|
|
61
62
|
};
|
|
@@ -115,7 +116,7 @@ class Handoff extends Component {
|
|
|
115
116
|
) }
|
|
116
117
|
{ Name && 'active' !== Status && (
|
|
117
118
|
<Button className={ classes } variant="secondary" disabled { ...otherProps }>
|
|
118
|
-
{ Name + __( ' not installed', 'newspack' ) }
|
|
119
|
+
{ Name + __( ' not installed', 'newspack-plugin' ) }
|
|
119
120
|
</Button>
|
|
120
121
|
) }
|
|
121
122
|
{ ! Name && (
|
|
@@ -126,7 +127,7 @@ class Handoff extends Component {
|
|
|
126
127
|
>
|
|
127
128
|
<Fragment>
|
|
128
129
|
{ ! compact && <Waiting isLeft /> }
|
|
129
|
-
{ __( 'Retrieving Plugin Info', 'newspack' ) }
|
|
130
|
+
{ __( 'Retrieving Plugin Info', 'newspack-plugin' ) }
|
|
130
131
|
</Fragment>
|
|
131
132
|
</Button>
|
|
132
133
|
) }
|
|
@@ -34,6 +34,8 @@ export default function HandoffMessage() {
|
|
|
34
34
|
// Clean up the notification when unmounting.
|
|
35
35
|
return () => window.localStorage.removeItem( HANDOFF_KEY );
|
|
36
36
|
}, [] );
|
|
37
|
-
if ( ! handoffMessage )
|
|
37
|
+
if ( ! handoffMessage ) {
|
|
38
|
+
return null;
|
|
39
|
+
}
|
|
38
40
|
return <Notice isHandoff isDismissible={ false } rawHTML noticeText={ handoffMessage } />;
|
|
39
41
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WordPress dependencies
|
|
3
|
+
*/
|
|
4
|
+
import { useRef } from '@wordpress/element';
|
|
5
|
+
|
|
6
|
+
import usePrompt from './usePrompt';
|
|
7
|
+
import useObjectState from './useObjectState';
|
|
8
|
+
import useOnClickOutside from './useOnClickOutside';
|
|
9
|
+
|
|
10
|
+
const useUniqueId = ( prefix: string ) => {
|
|
11
|
+
const id = useRef( `${ prefix }-${ Math.round( Math.random() * 99999 ) }` );
|
|
12
|
+
return id.current;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export default { usePrompt, useObjectState, useOnClickOutside, useUniqueId };
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
// https://gist.github.com/sibelius/60a4e11da1f826b8d60dc3975a1ac805
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* External dependencies.
|
|
5
|
+
*/
|
|
6
|
+
import { useEffect, useRef } from '@wordpress/element';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Internal dependencies.
|
|
10
|
+
*/
|
|
11
|
+
import Router from '../proxied-imports/router';
|
|
12
|
+
|
|
13
|
+
const { useHistory } = Router;
|
|
14
|
+
|
|
15
|
+
export default ( when: boolean, message: string ): ( () => void ) => {
|
|
16
|
+
const history = useHistory();
|
|
17
|
+
const self = useRef( null );
|
|
18
|
+
|
|
19
|
+
const onWindowOrTabClose = ( event: Event | undefined ) => {
|
|
20
|
+
if ( ! when ) {
|
|
21
|
+
return;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
if ( typeof event === 'undefined' ) {
|
|
25
|
+
event = window.event;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
return message;
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
useEffect( () => {
|
|
32
|
+
if ( when ) {
|
|
33
|
+
self.current = history.block( message );
|
|
34
|
+
window.addEventListener( 'beforeunload', onWindowOrTabClose );
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
return () => {
|
|
38
|
+
if ( self.current ) {
|
|
39
|
+
( self.current as () => void )();
|
|
40
|
+
}
|
|
41
|
+
window.removeEventListener( 'beforeunload', onWindowOrTabClose );
|
|
42
|
+
};
|
|
43
|
+
}, [ message, when ] );
|
|
44
|
+
|
|
45
|
+
return self.current || ( () => {} );
|
|
46
|
+
};
|
|
@@ -92,7 +92,7 @@ class ImageUpload extends Component {
|
|
|
92
92
|
return (
|
|
93
93
|
<div className={ classnames( 'newspack-image-upload', className ) }>
|
|
94
94
|
<div className="newspack-image-upload__header">
|
|
95
|
-
{ /* eslint-disable-next-line jsx-a11y/label-has-for */ }
|
|
95
|
+
{ /* eslint-disable-next-line jsx-a11y/label-has-for, jsx-a11y/label-has-associated-control */ }
|
|
96
96
|
{ label && <label className="newspack-image-upload__label">{ label }</label> }
|
|
97
97
|
{ info && <InfoButton text={ info } /> }
|
|
98
98
|
</div>
|
|
@@ -102,11 +102,11 @@ class ImageUpload extends Component {
|
|
|
102
102
|
<img
|
|
103
103
|
data-testid="image-upload"
|
|
104
104
|
src={ image.url }
|
|
105
|
-
alt={ __( 'Image preview', 'newspack' ) }
|
|
105
|
+
alt={ __( 'Image preview', 'newspack-plugin' ) }
|
|
106
106
|
/>
|
|
107
107
|
<div className="newspack-image-upload__controls">
|
|
108
108
|
<Button disabled={ disabled } onClick={ this.openModal } isLink>
|
|
109
|
-
{ __( 'Replace', 'newspack' ) }
|
|
109
|
+
{ __( 'Replace', 'newspack-plugin' ) }
|
|
110
110
|
</Button>
|
|
111
111
|
<span className="sep" />
|
|
112
112
|
<Button
|
|
@@ -115,13 +115,13 @@ class ImageUpload extends Component {
|
|
|
115
115
|
isLink
|
|
116
116
|
isDestructive
|
|
117
117
|
>
|
|
118
|
-
{ __( 'Remove', 'newspack' ) }
|
|
118
|
+
{ __( 'Remove', 'newspack-plugin' ) }
|
|
119
119
|
</Button>
|
|
120
120
|
</div>
|
|
121
121
|
</>
|
|
122
122
|
) : (
|
|
123
123
|
<Button disabled={ disabled } onClick={ this.openModal } isLink>
|
|
124
|
-
{ buttonLabel ? buttonLabel : __( 'Upload', 'newspack' ) }
|
|
124
|
+
{ buttonLabel ? buttonLabel : __( 'Upload', 'newspack-plugin' ) }
|
|
125
125
|
</Button>
|
|
126
126
|
) }
|
|
127
127
|
</div>
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Image Upload
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
-
@use
|
|
5
|
+
@use "~@wordpress/base-styles/colors" as wp-colors;
|
|
6
6
|
|
|
7
7
|
.newspack-image-upload {
|
|
8
8
|
margin: 32px 0;
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
&--covering {
|
|
28
28
|
background-size: cover;
|
|
29
29
|
}
|
|
30
|
-
&:not(
|
|
30
|
+
&:not(&--has-image) {
|
|
31
31
|
.newspack-button {
|
|
32
32
|
background: white !important;
|
|
33
33
|
border-radius: 2px !important;
|
|
@@ -49,9 +49,9 @@
|
|
|
49
49
|
overflow: hidden;
|
|
50
50
|
&::before,
|
|
51
51
|
&::after {
|
|
52
|
-
border: 1px solid rgba(
|
|
52
|
+
border: 1px solid rgba(black, 0.54);
|
|
53
53
|
border-radius: 2px;
|
|
54
|
-
content:
|
|
54
|
+
content: "";
|
|
55
55
|
inset: 0;
|
|
56
56
|
position: absolute;
|
|
57
57
|
z-index: 0;
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
position: relative;
|
|
67
67
|
}
|
|
68
68
|
&::after {
|
|
69
|
-
background: rgba(
|
|
69
|
+
background: rgba(white, 0.9);
|
|
70
70
|
border-color: wp-colors.$gray-700;
|
|
71
71
|
}
|
|
72
72
|
&:focus-within,
|