@guardian/stand 0.0.15 → 0.0.16
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/dist/components/avatar/Avatar.cjs +2 -2
- package/dist/components/button/styles.cjs +7 -4
- package/dist/components/button/styles.js +7 -4
- package/dist/components/byline/Byline.cjs +15 -15
- package/dist/components/favicon/Favicon.cjs +2 -2
- package/dist/components/icon-button/IconButton.cjs +3 -3
- package/dist/components/icon-link-button/IconLinkButton.cjs +3 -3
- package/dist/components/menu/Menu.cjs +204 -0
- package/dist/components/menu/Menu.js +77 -0
- package/dist/components/menu/styles.cjs +103 -0
- package/dist/components/menu/styles.js +88 -0
- package/dist/components/tag-picker/TagTable.cjs +11 -11
- package/dist/index.cjs +4 -0
- package/dist/index.js +2 -0
- package/dist/menu.cjs +13 -0
- package/dist/menu.js +2 -0
- package/dist/styleD/build/css/component/menu.css +82 -0
- package/dist/styleD/build/css/semantic/shadow.css +7 -0
- package/dist/styleD/build/typescript/component/menu.cjs +140 -0
- package/dist/styleD/build/typescript/component/menu.js +138 -0
- package/dist/styleD/build/typescript/semantic/shadow.cjs +7 -0
- package/dist/styleD/build/typescript/semantic/shadow.js +5 -0
- package/dist/types/TopBar.d.ts +1 -1
- package/dist/types/avatar.d.ts +1 -1
- package/dist/types/button.d.ts +1 -1
- package/dist/types/byline.d.ts +1 -1
- package/dist/types/components/avatar/styles.d.ts +2 -1
- package/dist/types/components/button/styles.d.ts +2 -1
- package/dist/types/components/favicon/styles.d.ts +2 -1
- package/dist/types/components/icon/styles.d.ts +2 -1
- package/dist/types/components/icon-button/styles.d.ts +2 -1
- package/dist/types/components/icon-link-button/styles.d.ts +2 -1
- package/dist/types/components/link-button/styles.d.ts +2 -1
- package/dist/types/components/menu/Menu.d.ts +7 -0
- package/dist/types/components/menu/sandbox.d.ts +5 -0
- package/dist/types/components/menu/styles.d.ts +28 -0
- package/dist/types/components/menu/types.d.ts +63 -0
- package/dist/types/components/topbar/toolName/styles.d.ts +2 -1
- package/dist/types/components/typography/styles.d.ts +2 -1
- package/dist/types/favicon.d.ts +1 -1
- package/dist/types/icon-button.d.ts +1 -1
- package/dist/types/icon-link-button.d.ts +1 -1
- package/dist/types/icon.d.ts +1 -1
- package/dist/types/index.d.ts +4 -0
- package/dist/types/link-button.d.ts +1 -1
- package/dist/types/menu.d.ts +21 -0
- package/dist/types/styleD/build/typescript/component/menu.d.ts +140 -0
- package/dist/types/styleD/build/typescript/semantic/shadow.d.ts +7 -0
- package/dist/types/styleD/stories/semantic/Shadow.d.ts +1 -0
- package/dist/types/typography.d.ts +1 -1
- package/package.json +17 -2
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { SerializedStyles } from '@emotion/react';
|
|
2
2
|
import { type ComponentFavicon } from '../../styleD/build/typescript/component/favicon';
|
|
3
|
-
import type { Prettify } from '../../util/types';
|
|
3
|
+
import type { DeepPartial, Prettify } from '../../util/types';
|
|
4
4
|
export type FaviconTheme = Prettify<ComponentFavicon>;
|
|
5
|
+
export type PartialFaviconTheme = DeepPartial<FaviconTheme>;
|
|
5
6
|
export declare const defaultFaviconTheme: FaviconTheme;
|
|
6
7
|
export declare const faviconStyles: (theme: FaviconTheme) => SerializedStyles;
|
|
7
8
|
export declare const faviconTypographyStyles: (theme: FaviconTheme) => SerializedStyles;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { ComponentIcon } from '../../styleD/build/typescript/component/icon';
|
|
2
|
-
import type { Prettify } from '../../util/types';
|
|
2
|
+
import type { DeepPartial, Prettify } from '../../util/types';
|
|
3
3
|
import type { IconProps } from './types';
|
|
4
4
|
export type IconTheme = Prettify<ComponentIcon>;
|
|
5
|
+
export type PartialIconTheme = DeepPartial<IconTheme>;
|
|
5
6
|
export declare const defaultIconTheme: IconTheme;
|
|
6
7
|
export declare const iconStyles: (theme: IconTheme, { size, fill, mode, }: Required<Pick<IconProps, "size">> & Pick<IconProps, "fill"> & {
|
|
7
8
|
mode: 'text' | 'svg';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import type { ButtonTheme } from '../button/styles';
|
|
1
|
+
import type { ButtonTheme, PartialButtonTheme } from '../button/styles';
|
|
2
2
|
export type IconButtonTheme = ButtonTheme;
|
|
3
|
+
export type PartialIconButtonTheme = PartialButtonTheme;
|
|
3
4
|
export declare const defaultIconButtonTheme: ButtonTheme;
|
|
4
5
|
export declare const iconButtonStyles: (theme: {
|
|
5
6
|
shared: {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import type { ButtonTheme } from '../button/styles';
|
|
1
|
+
import type { ButtonTheme, PartialButtonTheme } from '../button/styles';
|
|
2
2
|
export type IconLinkButtonTheme = ButtonTheme;
|
|
3
|
+
export type PartialIconLinkButtonTheme = PartialButtonTheme;
|
|
3
4
|
export declare const defaultIconLinkButtonTheme: ButtonTheme;
|
|
4
5
|
export declare const iconLinkButtonStyles: (theme: {
|
|
5
6
|
shared: {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import type { ButtonTheme } from '../button/styles';
|
|
1
|
+
import type { ButtonTheme, PartialButtonTheme } from '../button/styles';
|
|
2
2
|
export type LinkButtonTheme = ButtonTheme;
|
|
3
|
+
export type PartialLinkButtonTheme = PartialButtonTheme;
|
|
3
4
|
export declare const defaultLinkButtonTheme: ButtonTheme;
|
|
4
5
|
export declare const linkButtonStyles: (theme: {
|
|
5
6
|
shared: {
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { DefaultPropsWithChildren } from '../../util/types';
|
|
2
|
+
import type { MenuItemProps, MenuProps, MenuSectionProps, MenuSeparatorProps } from './types';
|
|
3
|
+
export declare function MenuSeparator({ theme, cssOverrides, ...props }: MenuSeparatorProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
4
|
+
export declare function MenuToggle({ children }: DefaultPropsWithChildren<unknown>): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
5
|
+
export declare function MenuSection({ name, size, theme, cssOverrides, children, ...props }: MenuSectionProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
6
|
+
export declare function MenuItem({ label, description, aside, icon, size, theme, cssOverrides, ...props }: MenuItemProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare function Menu({ theme, size, popoverProps, menuTriggerProps, children, cssOverrides, ...props }: MenuProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const componentName = "Menu";
|
|
2
|
+
export declare const componentTsx = "import {\n\tMenu,\n\tMenuToggle,\n\tMenuSection,\n\tMenuItem,\n\tMenuSeparator,\n} from '@guardian/stand/menu';\nimport { IconButton } from '@guardian/stand/icon-button';\n\nexport const Component = () => (\n\t<Menu>\n\t\t<MenuToggle>\n\t\t\t<IconButton symbol=\"settings\" ariaLabel=\"Open menu\" />\n\t\t</MenuToggle>\n\n\t\t<MenuSection name=\"File actions\">\n\t\t\t<MenuItem\n\t\t\t\ticon=\"open_in_new\"\n\t\t\t\tlabel=\"Open\"\n\t\t\t\tdescription=\"Open in a new tab\"\n\t\t\t\tonAction={() => alert('open')}\n\t\t\t/>\n\t\t\t<MenuItem\n\t\t\t\ticon=\"edit\"\n\t\t\t\tlabel=\"Rename\"\n\t\t\t\tdescription=\"Rename the file\"\n\t\t\t\tonAction={() => alert('rename')}\n\t\t\t/>\n\t\t\t<MenuItem label=\"Delete\" onAction={() => alert('delete')} />\n\t\t</MenuSection>\n\n\t\t<MenuSeparator />\n\n\t\t<MenuSection>\n\t\t\t<MenuItem id=\"files\" label=\"Show files\" />\n\t\t\t<MenuItem id=\"folders\" label=\"Show folders\" />\n\t\t</MenuSection>\n\t</Menu>\n);\n";
|
|
3
|
+
export declare const componentCss = "@import '@guardian/stand/component/menu.css';\n@import \"@guardian/stand/fonts/MaterialSymbolsOutlined.css\";\n\n/* Popover container */\n.stand-popover {\n\toverflow: var(--component-menu-popover-shared-overflow);\n\tmax-width: var(--component-menu-popover-md-max-width);\n\twidth: var(--component-menu-popover-md-width);\n\tbox-shadow: var(--component-menu-popover-shared-shadow);\n}\n\n/* Menu list */\n.stand-menu {\n\tdisplay: var(--component-menu-menu-shared-display);\n\tflex-direction: var(--component-menu-menu-shared-flex-direction);\n\tbackground: var(--component-menu-menu-shared-background-color);\n\tborder: var(--component-menu-menu-shared-border);\n}\n\n/* Menu section header */\n.stand-menu-section-header {\n\tdisplay: var(--component-menu-menu-section-header-shared-display);\n\talign-items: var(--component-menu-menu-section-header-shared-align-items);\n\tpadding: var(--component-menu-menu-section-header-shared-padding-top)\n\t\tvar(--component-menu-menu-section-header-shared-padding-right)\n\t\tvar(--component-menu-menu-section-header-shared-padding-bottom)\n\t\tvar(--component-menu-menu-section-header-shared-padding-left);\n\theight: var(--component-menu-menu-section-header-md-height);\n\tbackground: var(--component-menu-menu-section-header-shared-background-color);\n\tfont: var(--component-menu-menu-section-header-md-typography-font);\n\tletter-spacing: var(--component-menu-menu-section-header-md-typography-letter-spacing);\n\tfont-variation-settings: \"wdth\" var(--component-menu-menu-section-header-md-typography-font-width);\n}\n\n/* Menu item */\n.stand-menu-item {\n\tdisplay: var(--component-menu-menu-item-shared-display);\n\tgrid-template-columns: var(--component-menu-menu-item-shared-grid-template-columns);\n\tgrid-template-areas: var(--component-menu-menu-item-shared-grid-template-areas);\n\tgap: var(--component-menu-menu-item-shared-gap);\n\talign-items: var(--component-menu-menu-item-shared-align-items);\n\tpadding: var(--component-menu-menu-item-shared-padding-top)\n\t\tvar(--component-menu-menu-item-shared-padding-right)\n\t\tvar(--component-menu-menu-item-shared-padding-bottom)\n\t\tvar(--component-menu-menu-item-shared-padding-left);\n\tborder-bottom: var(--component-menu-menu-item-shared-border-bottom);\n\tcursor: pointer;\n}\n.stand-menu-item-with-description {\n\tgrid-template-areas: var(--component-menu-menu-item-shared-grid-template-areas-with-description);\n}\n.stand-menu-item:last-child {\n\tborder-bottom: var(--component-menu-menu-item-shared-last-child-border-bottom);\n}\n.stand-menu-item:hover {\n\tbackground: var(--component-menu-menu-item-shared-hover-background-color);\n}\n.stand-menu-item:focus-visible {\n\toutline: var(--component-menu-menu-item-shared-focus-visible-outline);\n\toutline-offset: var(--component-menu-menu-item-shared-focus-visible-outline-offset);\n\tbackground: var(--component-menu-menu-item-shared-hover-background-color);\n}\n\n.stand-menu-item-icon {\n\tgrid-area: var(--component-menu-menu-item-shared-icon-grid-area);\n\talign-self: var(--component-menu-menu-item-shared-icon-align-self);\n\tcolor: var(--component-menu-menu-item-shared-icon-color);\n\tfont-size: var(--component-menu-menu-item-md-icon-size);\n\tline-height: var(--component-menu-menu-item-md-icon-line-height);\n}\n.stand-menu-item-label {\n\tgrid-area: var(--component-menu-menu-item-shared-label-grid-area);\n\tcolor: var(--component-menu-menu-item-shared-label-color);\n\tfont: var(--component-menu-menu-item-shared-label-typography-font);\n\tletter-spacing: var(--component-menu-menu-item-shared-label-typography-letter-spacing);\n\tfont-variation-settings: \"wdth\" var(--component-menu-menu-item-shared-label-typography-font-width);\n}\n.stand-menu-item-description {\n\tgrid-area: var(--component-menu-menu-item-shared-description-grid-area);\n\tcolor: var(--component-menu-menu-item-shared-description-color);\n\tfont: var(--component-menu-menu-item-shared-description-typography-font);\n\tletter-spacing: var(--component-menu-menu-item-shared-description-typography-letter-spacing);\n\tfont-variation-settings: \"wdth\" var(--component-menu-menu-item-shared-description-typography-font-width);\n}\n.stand-menu-item-aside {\n\tgrid-area: var(--component-menu-menu-item-shared-aside-grid-area);\n\tjustify-self: var(--component-menu-menu-item-shared-aside-justify-self);\n\tcolor: var(--component-menu-menu-item-shared-aside-color);\n\tfont: var(--component-menu-menu-item-shared-aside-typography-font);\n\tletter-spacing: var(--component-menu-menu-item-shared-aside-typography-letter-spacing);\n\tfont-variation-settings: \"wdth\" var(--component-menu-menu-item-shared-aside-typography-font-width);\n}\n\n/* Separator */\n.stand-menu-separator {\n\tbackground-color: var(--component-menu-menu-separator-shared-background-color);\n\theight: var(--component-menu-menu-separator-shared-height);\n\twidth: var(--component-menu-menu-separator-shared-width);\n}\n";
|
|
4
|
+
export declare const componentHtml = "<div class=\"stand-popover\">\n\t<div class=\"stand-menu\">\n\t\t<div>\n\t\t\t<div class=\"stand-menu-section-header\">File actions</div>\n\t\t\t<div class=\"stand-menu-item stand-menu-item-with-description\" tabindex=\"0\">\n\t\t\t\t<span class=\"stand-menu-item-icon material-symbols\">open_in_new</span>\n\t\t\t\t<span class=\"stand-menu-item-label\">Open</span>\n\t\t\t\t<span class=\"stand-menu-item-description\">Open in a new tab</span>\n\t\t\t\t<span class=\"stand-menu-item-aside\">\u2318O</span>\n\t\t\t</div>\n\t\t\t<div class=\"stand-menu-item stand-menu-item-with-description\" tabindex=\"0\">\n\t\t\t\t<span class=\"stand-menu-item-label\">Rename</span>\n\t\t\t\t<span class=\"stand-menu-item-description\">Rename the file</span>\n\t\t\t</div>\n\t\t\t<div class=\"stand-menu-item\" tabindex=\"0\">\n\t\t\t\t<span class=\"stand-menu-item-label\">Delete</span>\n\t\t\t</div>\n\t\t</div>\n\t\t<div class=\"stand-menu-separator\"></div>\n\t\t<div>\n\t\t\t<div class=\"stand-menu-item\" tabindex=\"0\">\n\t\t\t\t<span class=\"stand-menu-item-label\">Show files</span>\n\t\t\t</div>\n\t\t\t<div class=\"stand-menu-item\" tabindex=\"0\">\n\t\t\t\t<span class=\"stand-menu-item-label\">Show folders</span>\n\t\t\t</div>\n\t\t</div>\n\t</div>\n</div>\n";
|
|
5
|
+
export declare const componentJs = "import { componentMenu } from \"@guardian/stand\";\n\nconst { menu, menuItem, menuSection, menuSeparator, popover } = componentMenu;\n\n// example of creating a stylesheet in js\nconst sheet = new CSSStyleSheet();\n\n// apply the rules to the sheet\nsheet.replaceSync(`\n\t/* Popover container */\n\t.js-stand-popover {\n\t\toverflow: ${popover.shared.overflow};\n\t\tmax-width: ${popover.md['max-width']};\n\t\twidth: ${popover.md.width};\n\t\tbox-shadow: ${popover.shared.shadow};\n\t}\n\n\t/* Menu list */\n\t.js-stand-menu {\n\t\tdisplay: ${menu.shared.display};\n\t\tflex-direction: ${menu.shared['flex-direction']};\n\t\tbackground: ${menu.shared['background-color']};\n\t\tborder: ${menu.shared.border};\n\t}\n\n\t/* Menu section header */\n\t.js-stand-menu-section-header {\n\t\tdisplay: ${menuSection.header.shared.display};\n\t\talign-items: ${menuSection.header.shared['align-items']};\n\t\theight: ${menuSection.header.md.height};\n\t\tbackground: ${menuSection.header.shared['background-color']};\n\t\tpadding: ${menuSection.header.shared.padding.top} ${menuSection.header.shared.padding.right} ${menuSection.header.shared.padding.bottom} ${menuSection.header.shared.padding.left};\n\t\tfont: ${menuSection.header.md.typography.font};\n\t\tletter-spacing: ${menuSection.header.md.typography.letterSpacing};\n\t\tfont-variation-settings: 'wdth' ${menuSection.header.md.typography.fontWidth};\n\t}\n\n\t/* Menu item */\n\t.js-stand-menu-item {\n\t\tdisplay: ${menuItem.shared.display};\n\t\tgrid-template-columns: ${menuItem.shared['grid-template-columns']};\n\t\tgrid-template-areas: ${menuItem.shared['grid-template-areas']};\n\t\tgap: ${menuItem.shared.gap};\n\t\talign-items: ${menuItem.shared['align-items']};\n\t\tpadding: ${menuItem.shared.padding.top} ${menuItem.shared.padding.right} ${menuItem.shared.padding.bottom} ${menuItem.shared.padding.left};\n\t\tborder-bottom: ${menuItem.shared['border-bottom']};\n\t\tcursor: pointer;\n\t}\n\t.js-stand-menu-item-with-description {\n\t\tgrid-template-areas: ${menuItem.shared['grid-template-areas-with-description']};\n\t}\n\t.js-stand-menu-item:last-child {\n\t\tborder-bottom: ${menuItem.shared[':last-child']['border-bottom']};\n\t}\n\t.js-stand-menu-item:hover {\n\t\tbackground: ${menuItem.shared[':hover']['background-color']};\n\t}\n\t.js-stand-menu-item:focus-visible {\n\t\toutline: ${menuItem.shared[':focus-visible'].outline};\n\t\toutline-offset: ${menuItem.shared[':focus-visible']['outline-offset']};\n\t\tbackground: ${menuItem.shared[':hover']['background-color']};\n\t}\n\n\t.js-stand-menu-item-icon {\n\t\tgrid-area: ${menuItem.shared.icon['grid-area']};\n\t\talign-self: ${menuItem.shared.icon['align-self']};\n\t\tcolor: ${menuItem.shared.icon.color};\n\t\tfont-size: ${menuItem.md.icon.size};\n\t\tline-height: ${menuItem.md.icon['line-height']};\n\t}\n\t.js-stand-menu-item-label {\n\t\tgrid-area: ${menuItem.shared.label['grid-area']};\n\t\tcolor: ${menuItem.shared.label.color};\n\t\tfont: ${menuItem.shared.label.typography.font};\n\t\tletter-spacing: ${menuItem.shared.label.typography.letterSpacing};\n\t\tfont-variation-settings: 'wdth' ${menuItem.shared.label.typography.fontWidth};\n\t}\n\t.js-stand-menu-item-description {\n\t\tgrid-area: ${menuItem.shared.description['grid-area']};\n\t\tcolor: ${menuItem.shared.description.color};\n\t\tfont: ${menuItem.shared.description.typography.font};\n\t\tletter-spacing: ${menuItem.shared.description.typography.letterSpacing};\n\t\tfont-variation-settings: 'wdth' ${menuItem.shared.description.typography.fontWidth};\n\t}\n\t.js-stand-menu-item-aside {\n\t\tgrid-area: ${menuItem.shared.aside['grid-area']};\n\t\tjustify-self: ${menuItem.shared.aside['justify-self']};\n\t\tcolor: ${menuItem.shared.aside.color};\n\t\tfont: ${menuItem.shared.aside.typography.font};\n\t\tletter-spacing: ${menuItem.shared.aside.typography.letterSpacing};\n\t\tfont-variation-settings: 'wdth' ${menuItem.shared.aside.typography.fontWidth};\n\t}\n\n\t/* Separator */\n\t.js-stand-menu-separator {\n\t\tbackground-color: ${menuSeparator.shared['background-color']};\n\t\theight: ${menuSeparator.shared.height};\n\t\twidth: ${menuSeparator.shared.width};\n\t}\n`);\n\n// update the document with the sheet\ndocument.adoptedStyleSheets.push(sheet);\n\n// modify the dom with the menu components using the generated stylesheet\ndocument.getElementById(\"app\").innerHTML = `\n\t<div class=\"js-stand-popover\">\n\t\t<div class=\"js-stand-menu\">\n\t\t\t<div>\n\t\t\t\t<div class=\"js-stand-menu-section-header\">File actions</div>\n\t\t\t\t<div class=\"js-stand-menu-item js-stand-menu-item-with-description\" tabindex=\"0\">\n\t\t\t\t\t<span class=\"js-stand-menu-item-icon material-symbols\">open_in_new</span>\n\t\t\t\t\t<span class=\"js-stand-menu-item-label\">Open</span>\n\t\t\t\t\t<span class=\"js-stand-menu-item-description\">Open in a new tab</span>\n\t\t\t\t\t<span class=\"js-stand-menu-item-aside\">\u2318O</span>\n\t\t\t\t</div>\n\t\t\t\t<div class=\"js-stand-menu-item js-stand-menu-item-with-description\" tabindex=\"0\">\n\t\t\t\t\t<span class=\"js-stand-menu-item-label\">Rename</span>\n\t\t\t\t\t<span class=\"js-stand-menu-item-description\">Rename the file</span>\n\t\t\t\t</div>\n\t\t\t\t<div class=\"js-stand-menu-item\" tabindex=\"0\">\n\t\t\t\t\t<span class=\"js-stand-menu-item-label\">Delete</span>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div class=\"js-stand-menu-separator\"></div>\n\t\t\t<div>\n\t\t\t\t<div class=\"js-stand-menu-item\" tabindex=\"0\">\n\t\t\t\t\t<span class=\"js-stand-menu-item-label\">Show files</span>\n\t\t\t\t</div>\n\t\t\t\t<div class=\"js-stand-menu-item\" tabindex=\"0\">\n\t\t\t\t\t<span class=\"js-stand-menu-item-label\">Show folders</span>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</div>\n\t</div>\n`;\n";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import type { SerializedStyles } from '@emotion/react';
|
|
2
|
+
import type { ComponentMenu } from '../../styleD/build/typescript/component/menu';
|
|
3
|
+
import type { DeepPartial, Prettify } from '../../util/types';
|
|
4
|
+
import type { MenuItemProps, MenuPopoverProps, MenuSectionProps } from './types';
|
|
5
|
+
export type MenuTheme = Prettify<ComponentMenu['menu']>;
|
|
6
|
+
export type PartialMenuTheme = DeepPartial<MenuTheme>;
|
|
7
|
+
export declare const defaultMenuTheme: MenuTheme;
|
|
8
|
+
export declare const menuStyles: (theme: MenuTheme) => SerializedStyles;
|
|
9
|
+
export type MenuSectionTheme = Prettify<ComponentMenu['menuSection']>;
|
|
10
|
+
export type PartialMenuSectionTheme = DeepPartial<MenuSectionTheme>;
|
|
11
|
+
export declare const defaultMenuSectionTheme: MenuSectionTheme;
|
|
12
|
+
export declare const menuSectionHeaderStyles: (theme: MenuSectionTheme, { size }: Required<Pick<MenuSectionProps, 'size'>>) => SerializedStyles;
|
|
13
|
+
export type MenuItemTheme = Prettify<ComponentMenu['menuItem']>;
|
|
14
|
+
export type PartialMenuItemTheme = DeepPartial<MenuItemTheme>;
|
|
15
|
+
export declare const defaultMenuItemTheme: MenuItemTheme;
|
|
16
|
+
export declare const menuItemStyles: (theme: MenuItemTheme, { description }: Pick<MenuItemProps, 'description'>, isFocusVisible?: boolean) => SerializedStyles;
|
|
17
|
+
export declare const menuItemIconStyles: (theme: MenuItemTheme, { size }: Required<Pick<MenuItemProps, 'size'>>) => SerializedStyles;
|
|
18
|
+
export declare const menuItemLabelStyles: (theme: MenuItemTheme) => SerializedStyles;
|
|
19
|
+
export declare const menuItemDescriptionStyles: (theme: MenuItemTheme) => SerializedStyles;
|
|
20
|
+
export declare const menuItemAsideStyles: (theme: MenuItemTheme) => SerializedStyles;
|
|
21
|
+
export type MenuSeparatorTheme = Prettify<ComponentMenu['menuSeparator']>;
|
|
22
|
+
export type PartialMenuSeparatorTheme = DeepPartial<MenuSeparatorTheme>;
|
|
23
|
+
export declare const defaultMenuSeparatorTheme: MenuSeparatorTheme;
|
|
24
|
+
export declare const menuSeparatorStyles: (theme: MenuSeparatorTheme) => SerializedStyles;
|
|
25
|
+
export type MenuPopoverTheme = Prettify<ComponentMenu['menuPopover']>;
|
|
26
|
+
export type PartialMenuPopoverTheme = DeepPartial<MenuPopoverTheme>;
|
|
27
|
+
export declare const defaultMenuPopoverTheme: MenuPopoverTheme;
|
|
28
|
+
export declare const menuPopoverStyles: (theme: MenuPopoverTheme, { size }: Required<Pick<MenuPopoverProps, 'size'>>) => SerializedStyles;
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { MenuItemProps as RACMenuItemProps, MenuProps as RACMenuProps, MenuSectionProps as RACMenuSectionProps, MenuTriggerProps as RACMenuTriggerProps, PopoverProps as RACPopoverProps, SeparatorProps as RACSeparatorProps } from 'react-aria-components';
|
|
3
|
+
import type { DefaultProps, DefaultPropsWithChildren } from '../../util/types';
|
|
4
|
+
import type { IconProps } from '../icon/types';
|
|
5
|
+
import type { MenuItemTheme, MenuPopoverTheme, MenuSectionTheme, MenuSeparatorTheme, MenuTheme } from './styles';
|
|
6
|
+
export interface MenuProps extends DefaultPropsWithChildren<MenuTheme, RACMenuProps<object>['className']>, Omit<RACMenuProps<object>, 'children'> {
|
|
7
|
+
/**
|
|
8
|
+
* Size variant of the Menu
|
|
9
|
+
*/
|
|
10
|
+
size?: MenuPopoverProps['size'];
|
|
11
|
+
/**
|
|
12
|
+
* Props to pass to the underlying React Aria Popover component
|
|
13
|
+
*/
|
|
14
|
+
popoverProps?: Omit<MenuPopoverProps, 'children' | 'size'>;
|
|
15
|
+
/**
|
|
16
|
+
* Props to pass to the underlying React Aria MenuTrigger component
|
|
17
|
+
*/
|
|
18
|
+
menuTriggerProps?: Omit<MenuTriggerProps, 'children'>;
|
|
19
|
+
}
|
|
20
|
+
export interface MenuSectionProps extends DefaultPropsWithChildren<MenuSectionTheme, RACMenuSectionProps<object>['className']>, Omit<RACMenuSectionProps<object>, 'children'> {
|
|
21
|
+
/**
|
|
22
|
+
* The (optional) name of the section to be displayed in a header
|
|
23
|
+
*/
|
|
24
|
+
name?: string;
|
|
25
|
+
/**
|
|
26
|
+
* Size variant of the MenuSection, this doesn't need to be passed if the MenuSection is a child of Menu, as it will inherit the size of the Menu.
|
|
27
|
+
*/
|
|
28
|
+
size?: MenuPopoverProps['size'];
|
|
29
|
+
/**
|
|
30
|
+
* Disable the selectionMode option for the time being, as we currently don't have a checkbox or radio button component to use for the selectable menu items that this would require. This can be added in the future when we have these components available.
|
|
31
|
+
*/
|
|
32
|
+
selectionMode?: 'none';
|
|
33
|
+
}
|
|
34
|
+
export interface MenuItemProps extends DefaultProps<MenuItemTheme, RACMenuItemProps['className']>, Omit<RACMenuItemProps, 'children'> {
|
|
35
|
+
/**
|
|
36
|
+
* The main label of the menu item, this can be a string or any React node if more complex layout is needed.
|
|
37
|
+
*/
|
|
38
|
+
label: React.ReactNode;
|
|
39
|
+
/**
|
|
40
|
+
* Optional description text for the menu item, this can be a string or any React node if more complex layout is needed. The description will be rendered below the label in a smaller font size.
|
|
41
|
+
*/
|
|
42
|
+
description?: React.ReactNode;
|
|
43
|
+
/**
|
|
44
|
+
* Optional content to be rendered on the right side of the menu item, this can be used for things like keyboard shortcuts or badges. This can be a string or any React node if more complex layout is needed.
|
|
45
|
+
*/
|
|
46
|
+
aside?: React.ReactNode;
|
|
47
|
+
/**
|
|
48
|
+
* Icon to be rendered within the left side of the menu item. Passed to the Icon component, so can be either a string (for material symbols) or an SVG element.
|
|
49
|
+
*/
|
|
50
|
+
icon?: IconProps['symbol'] | Exclude<IconProps['children'], string>;
|
|
51
|
+
/**
|
|
52
|
+
* Size variant of the MenuItem, this doesn't need to be passed if the MenuItem is a child of Menu, as it will inherit the size of the Menu.
|
|
53
|
+
*/
|
|
54
|
+
size?: MenuPopoverProps['size'];
|
|
55
|
+
}
|
|
56
|
+
export type MenuSeparatorProps = DefaultProps<MenuSeparatorTheme, RACSeparatorProps['className']>;
|
|
57
|
+
export interface MenuPopoverProps extends DefaultProps<MenuPopoverTheme, RACPopoverProps['className']>, RACPopoverProps {
|
|
58
|
+
/**
|
|
59
|
+
* Size variant of the Popover, this doesn't need to be passed if the Popover is a child of Menu, as it will inherit the size of the Menu.
|
|
60
|
+
*/
|
|
61
|
+
size?: keyof Omit<MenuPopoverTheme, 'shared'>;
|
|
62
|
+
}
|
|
63
|
+
export type MenuTriggerProps = RACMenuTriggerProps;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { SerializedStyles } from '@emotion/react';
|
|
2
2
|
import { type ComponentTopBar } from '../../..//styleD/build/typescript/component/TopBar';
|
|
3
|
-
import type { Prettify } from '../../../util/types';
|
|
3
|
+
import type { DeepPartial, Prettify } from '../../../util/types';
|
|
4
4
|
export type TopBarToolNameTheme = Prettify<ComponentTopBar['ToolName']>;
|
|
5
|
+
export type PartialTopBarToolNameTheme = DeepPartial<TopBarToolNameTheme>;
|
|
5
6
|
export declare const defaultToolNameTheme: TopBarToolNameTheme;
|
|
6
7
|
export declare const toolNameStyles: (theme: TopBarToolNameTheme) => SerializedStyles;
|
|
7
8
|
export declare const toolNameTypography: (theme: TopBarToolNameTheme) => SerializedStyles;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { SerializedStyles } from '@emotion/react';
|
|
2
2
|
import { type ComponentTypography } from '../../styleD/build/typescript/component/typography';
|
|
3
|
-
import type { Prettify } from '../../util/types';
|
|
3
|
+
import type { DeepPartial, Prettify } from '../../util/types';
|
|
4
4
|
import type { TypographyProps } from './types';
|
|
5
5
|
export type TypographyTheme = Prettify<ComponentTypography>;
|
|
6
|
+
export type PartialTypographyTheme = DeepPartial<TypographyTheme>;
|
|
6
7
|
export declare const defaultTypographyTheme: TypographyTheme;
|
|
7
8
|
export declare const typographyStyles: (theme: TypographyTheme, { variant }: Required<Pick<TypographyProps, 'variant'>>) => SerializedStyles;
|
package/dist/types/favicon.d.ts
CHANGED
|
@@ -14,6 +14,6 @@
|
|
|
14
14
|
*/
|
|
15
15
|
export { Favicon } from './components/favicon/Favicon';
|
|
16
16
|
export type { FaviconProps } from './components/favicon/types';
|
|
17
|
-
export type { FaviconTheme } from './components/favicon/styles';
|
|
17
|
+
export type { PartialFaviconTheme as FaviconTheme } from './components/favicon/styles';
|
|
18
18
|
export { componentFavicon } from './styleD/build/typescript/component/favicon';
|
|
19
19
|
export type { ComponentFavicon } from './styleD/build/typescript/component/favicon';
|
|
@@ -17,4 +17,4 @@
|
|
|
17
17
|
*/
|
|
18
18
|
export { IconButton } from './components/icon-button/IconButton';
|
|
19
19
|
export type { IconButtonProps } from './components/icon-button/types';
|
|
20
|
-
export type { IconButtonTheme } from './components/icon-button/styles';
|
|
20
|
+
export type { PartialIconButtonTheme as IconButtonTheme } from './components/icon-button/styles';
|
|
@@ -17,4 +17,4 @@
|
|
|
17
17
|
*/
|
|
18
18
|
export { IconLinkButton } from './components/icon-link-button/IconLinkButton';
|
|
19
19
|
export type { IconLinkButtonProps } from './components/icon-link-button/types';
|
|
20
|
-
export type { IconLinkButtonTheme } from './components/icon-link-button/styles';
|
|
20
|
+
export type { PartialIconLinkButtonTheme as IconLinkButtonTheme } from './components/icon-link-button/styles';
|
package/dist/types/icon.d.ts
CHANGED
|
@@ -22,6 +22,6 @@
|
|
|
22
22
|
*/
|
|
23
23
|
export { Icon } from './components/icon/Icon';
|
|
24
24
|
export type { IconProps } from './components/icon/types';
|
|
25
|
-
export type { IconTheme } from './components/icon/styles';
|
|
25
|
+
export type { PartialIconTheme as IconTheme } from './components/icon/styles';
|
|
26
26
|
export { componentIcon } from './styleD/build/typescript/component/icon';
|
|
27
27
|
export type { ComponentIcon } from './styleD/build/typescript/component/icon';
|
package/dist/types/index.d.ts
CHANGED
|
@@ -26,6 +26,8 @@ export { componentIcon } from './styleD/build/typescript/component/icon';
|
|
|
26
26
|
export type { ComponentIcon } from './styleD/build/typescript/component/icon';
|
|
27
27
|
export { componentFavicon } from './styleD/build/typescript/component/favicon';
|
|
28
28
|
export type { ComponentFavicon } from './styleD/build/typescript/component/favicon';
|
|
29
|
+
export { componentMenu } from './styleD/build/typescript/component/menu';
|
|
30
|
+
export type { ComponentMenu } from './styleD/build/typescript/component/menu';
|
|
29
31
|
export { componentTopBar } from './styleD/build/typescript/component/TopBar';
|
|
30
32
|
export type { ComponentTopBar } from './styleD/build/typescript/component/TopBar';
|
|
31
33
|
/**
|
|
@@ -50,3 +52,5 @@ export { semanticTypography } from './styleD/build/typescript/semantic/typograph
|
|
|
50
52
|
export type { SemanticTypography } from './styleD/build/typescript/semantic/typography';
|
|
51
53
|
export { semanticSizing } from './styleD/build/typescript/semantic/sizing';
|
|
52
54
|
export type { SemanticSizing } from './styleD/build/typescript/semantic/sizing';
|
|
55
|
+
export { semanticShadow } from './styleD/build/typescript/semantic/shadow';
|
|
56
|
+
export type { SemanticShadow } from './styleD/build/typescript/semantic/shadow';
|
|
@@ -17,4 +17,4 @@
|
|
|
17
17
|
*/
|
|
18
18
|
export { LinkButton } from './components/link-button/LinkButton';
|
|
19
19
|
export type { LinkButtonProps } from './components/link-button/types';
|
|
20
|
-
export type { LinkButtonTheme } from './components/link-button/styles';
|
|
20
|
+
export type { PartialLinkButtonTheme as LinkButtonTheme } from './components/link-button/styles';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Menu component entry point
|
|
3
|
+
*
|
|
4
|
+
* Peer dependencies required to use these components:
|
|
5
|
+
* - `@emotion/react`
|
|
6
|
+
* - `react`
|
|
7
|
+
* - `react-dom`
|
|
8
|
+
* - `typescript`
|
|
9
|
+
* - `react-aria-components`
|
|
10
|
+
* - `@react-aria/focus`
|
|
11
|
+
*
|
|
12
|
+
* See the `peerDependencies` section of package.json for compatible versions.
|
|
13
|
+
*
|
|
14
|
+
* If you only need the built CSS (./component/menu.css),
|
|
15
|
+
* you don't need to install these.
|
|
16
|
+
*/
|
|
17
|
+
export { Menu, MenuItem, MenuSection, MenuSeparator, MenuToggle, } from './components/menu/Menu';
|
|
18
|
+
export type { MenuProps, MenuItemProps, MenuSectionProps, MenuSeparatorProps, MenuTriggerProps, MenuPopoverProps as PopoverProps, } from './components/menu/types';
|
|
19
|
+
export type { PartialMenuTheme as MenuTheme, PartialMenuItemTheme as MenuItemTheme, PartialMenuSectionTheme as MenuSectionTheme, PartialMenuSeparatorTheme as MenuSeparatorTheme, PartialMenuPopoverTheme as MenuPopoverTheme, } from './components/menu/styles';
|
|
20
|
+
export { componentMenu } from './styleD/build/typescript/component/menu';
|
|
21
|
+
export type { ComponentMenu } from './styleD/build/typescript/component/menu';
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Do not edit directly, this file was auto-generated.
|
|
3
|
+
*/
|
|
4
|
+
export declare const componentMenu: {
|
|
5
|
+
menu: {
|
|
6
|
+
shared: {
|
|
7
|
+
display: string;
|
|
8
|
+
'flex-direction': string;
|
|
9
|
+
'background-color': string;
|
|
10
|
+
border: string;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
menuSection: {
|
|
14
|
+
header: {
|
|
15
|
+
shared: {
|
|
16
|
+
display: string;
|
|
17
|
+
'align-items': string;
|
|
18
|
+
padding: {
|
|
19
|
+
top: string;
|
|
20
|
+
right: string;
|
|
21
|
+
bottom: string;
|
|
22
|
+
left: string;
|
|
23
|
+
};
|
|
24
|
+
'background-color': string;
|
|
25
|
+
color: string;
|
|
26
|
+
};
|
|
27
|
+
sm: {
|
|
28
|
+
height: string;
|
|
29
|
+
typography: {
|
|
30
|
+
font: string;
|
|
31
|
+
letterSpacing: string;
|
|
32
|
+
fontWidth: number;
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
md: {
|
|
36
|
+
height: string;
|
|
37
|
+
typography: {
|
|
38
|
+
font: string;
|
|
39
|
+
letterSpacing: string;
|
|
40
|
+
fontWidth: number;
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
};
|
|
44
|
+
};
|
|
45
|
+
menuItem: {
|
|
46
|
+
shared: {
|
|
47
|
+
display: string;
|
|
48
|
+
'grid-template-areas': string;
|
|
49
|
+
'grid-template-areas-with-description': string;
|
|
50
|
+
'grid-template-columns': string;
|
|
51
|
+
gap: string;
|
|
52
|
+
'align-items': string;
|
|
53
|
+
padding: {
|
|
54
|
+
top: string;
|
|
55
|
+
right: string;
|
|
56
|
+
bottom: string;
|
|
57
|
+
left: string;
|
|
58
|
+
};
|
|
59
|
+
'border-bottom': string;
|
|
60
|
+
icon: {
|
|
61
|
+
'grid-area': string;
|
|
62
|
+
'align-self': string;
|
|
63
|
+
color: string;
|
|
64
|
+
};
|
|
65
|
+
label: {
|
|
66
|
+
'grid-area': string;
|
|
67
|
+
color: string;
|
|
68
|
+
typography: {
|
|
69
|
+
font: string;
|
|
70
|
+
letterSpacing: string;
|
|
71
|
+
fontWidth: number;
|
|
72
|
+
};
|
|
73
|
+
};
|
|
74
|
+
description: {
|
|
75
|
+
'grid-area': string;
|
|
76
|
+
color: string;
|
|
77
|
+
typography: {
|
|
78
|
+
font: string;
|
|
79
|
+
letterSpacing: string;
|
|
80
|
+
fontWidth: number;
|
|
81
|
+
};
|
|
82
|
+
};
|
|
83
|
+
aside: {
|
|
84
|
+
'grid-area': string;
|
|
85
|
+
'justify-self': string;
|
|
86
|
+
'align-self': string;
|
|
87
|
+
color: string;
|
|
88
|
+
typography: {
|
|
89
|
+
font: string;
|
|
90
|
+
letterSpacing: string;
|
|
91
|
+
fontWidth: number;
|
|
92
|
+
};
|
|
93
|
+
};
|
|
94
|
+
':last-child': {
|
|
95
|
+
'border-bottom': string;
|
|
96
|
+
};
|
|
97
|
+
':hover': {
|
|
98
|
+
'background-color': string;
|
|
99
|
+
};
|
|
100
|
+
':focus-visible': {
|
|
101
|
+
outline: string;
|
|
102
|
+
'outline-offset': string;
|
|
103
|
+
};
|
|
104
|
+
};
|
|
105
|
+
sm: {
|
|
106
|
+
icon: {
|
|
107
|
+
size: string;
|
|
108
|
+
'line-height': number;
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
md: {
|
|
112
|
+
icon: {
|
|
113
|
+
size: string;
|
|
114
|
+
'line-height': number;
|
|
115
|
+
};
|
|
116
|
+
};
|
|
117
|
+
};
|
|
118
|
+
menuSeparator: {
|
|
119
|
+
shared: {
|
|
120
|
+
'background-color': string;
|
|
121
|
+
height: string;
|
|
122
|
+
width: string;
|
|
123
|
+
};
|
|
124
|
+
};
|
|
125
|
+
menuPopover: {
|
|
126
|
+
shared: {
|
|
127
|
+
overflow: string;
|
|
128
|
+
shadow: string;
|
|
129
|
+
};
|
|
130
|
+
sm: {
|
|
131
|
+
'max-width': string;
|
|
132
|
+
width: string;
|
|
133
|
+
};
|
|
134
|
+
md: {
|
|
135
|
+
'max-width': string;
|
|
136
|
+
width: string;
|
|
137
|
+
};
|
|
138
|
+
};
|
|
139
|
+
};
|
|
140
|
+
export type ComponentMenu = typeof componentMenu;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const SemanticShadowTokens: () => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -14,6 +14,6 @@
|
|
|
14
14
|
*/
|
|
15
15
|
export { Typography } from './components/typography/Typography';
|
|
16
16
|
export type { TypographyProps } from './components/typography/types';
|
|
17
|
-
export type { TypographyTheme } from './components/typography/styles';
|
|
17
|
+
export type { PartialTypographyTheme as TypographyTheme } from './components/typography/styles';
|
|
18
18
|
export { componentTypography } from './styleD/build/typescript/component/typography';
|
|
19
19
|
export type { ComponentTypography } from './styleD/build/typescript/component/typography';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@guardian/stand",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.16",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"//exports": "Each component has its own entry point for optimal tree-shaking. Main entry point only includes design tokens and utilities. New components/foundations should follow the same pattern.",
|
|
6
6
|
"exports": {
|
|
@@ -49,6 +49,11 @@
|
|
|
49
49
|
"import": "./dist/favicon.js",
|
|
50
50
|
"require": "./dist/favicon.cjs"
|
|
51
51
|
},
|
|
52
|
+
"./menu": {
|
|
53
|
+
"types": "./dist/types/menu.d.ts",
|
|
54
|
+
"import": "./dist/menu.js",
|
|
55
|
+
"require": "./dist/menu.cjs"
|
|
56
|
+
},
|
|
52
57
|
"./TopBar": {
|
|
53
58
|
"types": "./dist/types/TopBar.d.ts",
|
|
54
59
|
"import": "./dist/TopBar.js",
|
|
@@ -87,6 +92,7 @@
|
|
|
87
92
|
"./semantic/colors.css": "./dist/styleD/build/css/semantic/colors.css",
|
|
88
93
|
"./semantic/typography.css": "./dist/styleD/build/css/semantic/typography.css",
|
|
89
94
|
"./semantic/sizing.css": "./dist/styleD/build/css/semantic/sizing.css",
|
|
95
|
+
"./semantic/shadow.css": "./dist/styleD/build/css/semantic/shadow.css",
|
|
90
96
|
"./component/byline.css": "./dist/styleD/build/css/component/byline.css",
|
|
91
97
|
"./component/tagAutocomplete.css": "./dist/styleD/build/css/component/tagAutocomplete.css",
|
|
92
98
|
"./component/tagTable.css": "./dist/styleD/build/css/component/tagTable.css",
|
|
@@ -96,6 +102,7 @@
|
|
|
96
102
|
"./component/typography.css": "./dist/styleD/build/css/component/typography.css",
|
|
97
103
|
"./component/icon.css": "./dist/styleD/build/css/component/icon.css",
|
|
98
104
|
"./component/favicon.css": "./dist/styleD/build/css/component/favicon.css",
|
|
105
|
+
"./component/menu.css": "./dist/styleD/build/css/component/menu.css",
|
|
99
106
|
"./component/TopBar.css": "./dist/styleD/build/css/component/TopBar.css"
|
|
100
107
|
},
|
|
101
108
|
"//typesVersions": "Provides backward compatibility for TypeScript moduleResolution: node - maps subpath imports to correct type definition files. When adding new components with their own entry points, ensure to add them here.",
|
|
@@ -139,6 +146,9 @@
|
|
|
139
146
|
],
|
|
140
147
|
"utils": [
|
|
141
148
|
"./dist/types/utils.d.ts"
|
|
149
|
+
],
|
|
150
|
+
"menu": [
|
|
151
|
+
"./dist/types/menu.d.ts"
|
|
142
152
|
]
|
|
143
153
|
}
|
|
144
154
|
},
|
|
@@ -163,6 +173,7 @@
|
|
|
163
173
|
"@guardian/tsconfig": "1.0.1",
|
|
164
174
|
"@material-design-icons/svg": "^0.14.15",
|
|
165
175
|
"@playwright/experimental-ct-react17": "^1.58.2",
|
|
176
|
+
"@react-aria/focus": "3.21.5",
|
|
166
177
|
"@rollup/plugin-commonjs": "29.0.0",
|
|
167
178
|
"@rollup/plugin-node-resolve": "16.0.3",
|
|
168
179
|
"@rollup/plugin-typescript": "12.3.0",
|
|
@@ -209,6 +220,7 @@
|
|
|
209
220
|
"peerDependencies": {
|
|
210
221
|
"@emotion/react": ">=11.11.4 <=11.14.0",
|
|
211
222
|
"@guardian/prosemirror-invisibles": "3.1.1",
|
|
223
|
+
"@react-aria/focus": "^3.21.5",
|
|
212
224
|
"prosemirror-dropcursor": "1.8.2",
|
|
213
225
|
"prosemirror-history": "1.4.1",
|
|
214
226
|
"prosemirror-keymap": "1.2.2",
|
|
@@ -216,7 +228,7 @@
|
|
|
216
228
|
"prosemirror-state": "1.4.3",
|
|
217
229
|
"prosemirror-view": "1.37.2",
|
|
218
230
|
"react": "^17.0.2 || ^18.0.0 || ^19.0.0",
|
|
219
|
-
"react-aria-components": ">= 1.13.0 <= 1.
|
|
231
|
+
"react-aria-components": ">= 1.13.0 <= 1.16.0",
|
|
220
232
|
"react-dom": "^17.0.2 || ^18.0.0 || ^19.0.0",
|
|
221
233
|
"typescript": ">=5.0.0 <=5.9.3"
|
|
222
234
|
},
|
|
@@ -227,6 +239,9 @@
|
|
|
227
239
|
"@guardian/prosemirror-invisibles": {
|
|
228
240
|
"optional": true
|
|
229
241
|
},
|
|
242
|
+
"@react-aria/focus": {
|
|
243
|
+
"optional": true
|
|
244
|
+
},
|
|
230
245
|
"prosemirror-dropcursor": {
|
|
231
246
|
"optional": true
|
|
232
247
|
},
|