@instructure/platform-block-content-editor 4.0.2 → 4.1.1
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/README.md +16 -1
- package/dist/components/MediaPlaceholder/MediaPlaceholder.d.ts +1 -1
- package/dist/components/MediaPlaceholder/MediaPlaceholder.d.ts.map +1 -1
- package/dist/components/blocks/Accordion/Accordion.d.ts.map +1 -1
- package/dist/components/blocks/Accordion/accordionPropsSchema.d.ts +7 -7
- package/dist/components/blocks/Accordion/createAccordionBlock.d.ts +1 -1
- package/dist/components/blocks/Accordion/getAccordionViewProps.d.ts +13 -11
- package/dist/components/blocks/Accordion/getAccordionViewProps.d.ts.map +1 -1
- package/dist/components/blocks/Banner/bannerPropsSchema.d.ts +9 -9
- package/dist/components/blocks/Banner/createBannerBlock.d.ts +3 -3
- package/dist/components/blocks/Banner/getBannerViewProps.d.ts +2 -2
- package/dist/components/blocks/Banner/getBannerViewProps.d.ts.map +1 -1
- package/dist/components/blocks/CodeBlock/codeBlockPropsSchema.d.ts +3 -3
- package/dist/components/blocks/CodeBlock/createCodeBlock.d.ts +1 -1
- package/dist/components/blocks/CodeBlock/getCodeBlockViewProps.d.ts +1 -1
- package/dist/components/blocks/CodeBlock/getCodeBlockViewProps.d.ts.map +1 -1
- package/dist/components/blocks/FlashCards/getFlashCardsViewProps.d.ts +1 -1
- package/dist/components/blocks/FlashCards/getFlashCardsViewProps.d.ts.map +1 -1
- package/dist/components/blocks/ImageBlock/createImageBlock.d.ts +2 -2
- package/dist/components/blocks/ImageBlock/imageBlockPropsSchema.d.ts +6 -6
- package/dist/components/blocks/InsetFocusRing.d.ts +14 -0
- package/dist/components/blocks/InsetFocusRing.d.ts.map +1 -0
- package/dist/components/blocks/KnowledgeCheck/createKnowledgeCheckBlock.d.ts +1 -1
- package/dist/components/blocks/KnowledgeCheck/getKnowledgeCheckViewProps.d.ts +1 -1
- package/dist/components/blocks/KnowledgeCheck/getKnowledgeCheckViewProps.d.ts.map +1 -1
- package/dist/components/blocks/KnowledgeCheck/knowledgeCheckPropsSchema.d.ts +7 -7
- package/dist/components/blocks/MixAndMatch/MatchCard.d.ts +3 -1
- package/dist/components/blocks/MixAndMatch/MatchCard.d.ts.map +1 -1
- package/dist/components/blocks/MixAndMatch/MixAndMatch.d.ts +4 -0
- package/dist/components/blocks/MixAndMatch/MixAndMatch.d.ts.map +1 -1
- package/dist/components/blocks/MixAndMatch/getMixAndMatchViewProps.d.ts +4 -2
- package/dist/components/blocks/MixAndMatch/getMixAndMatchViewProps.d.ts.map +1 -1
- package/dist/components/blocks/Quote/createQuoteBlock.d.ts +1 -1
- package/dist/components/blocks/Quote/quotePropsSchema.d.ts +3 -3
- package/dist/components/blocks/TabsBlock/createTabsBlock.d.ts +5 -5
- package/dist/components/blocks/TabsBlock/getTabsBlockViewProps.d.ts +4 -6
- package/dist/components/blocks/TabsBlock/getTabsBlockViewProps.d.ts.map +1 -1
- package/dist/components/blocks/TabsBlock/tabsBlockPropsSchema.d.ts +19 -19
- package/dist/components/blocks/VideoBlock/createVideoBlock.d.ts +2 -2
- package/dist/components/blocks/VideoBlock/videoBlockPropsSchema.d.ts +6 -6
- package/dist/components/blocks/brandTheming.d.ts +4 -4
- package/dist/components/blocks/brandTheming.d.ts.map +1 -1
- package/dist/components/blocks/commonViewProps.d.ts +1 -1
- package/dist/components/blocks/commonViewProps.d.ts.map +1 -1
- package/dist/contexts/RichTextEditorContext.d.ts +2 -0
- package/dist/contexts/RichTextEditorContext.d.ts.map +1 -1
- package/dist/editor/BlockContentEditor.d.ts +15 -1
- package/dist/editor/BlockContentEditor.d.ts.map +1 -1
- package/dist/editor/ai/BlockAIMenu.d.ts +1 -1
- package/dist/editor/ai/BlockAIMenu.d.ts.map +1 -1
- package/dist/editor/ai/BlockAIMenuContent.d.ts.map +1 -1
- package/dist/editor/ai/useBlockAIPopover.d.ts.map +1 -1
- package/dist/editor/canvas/DesignerArea.d.ts +7 -2
- package/dist/editor/canvas/DesignerArea.d.ts.map +1 -1
- package/dist/editor/canvas/DesignerCanvas.d.ts +4 -2
- package/dist/editor/canvas/DesignerCanvas.d.ts.map +1 -1
- package/dist/editor/canvas/GridDndProvider.d.ts +4 -1
- package/dist/editor/canvas/GridDndProvider.d.ts.map +1 -1
- package/dist/editor/canvas/GridItemChild.d.ts +0 -4
- package/dist/editor/canvas/GridItemChild.d.ts.map +1 -1
- package/dist/editor/canvas/GridItemContainer.d.ts +1 -5
- package/dist/editor/canvas/GridItemContainer.d.ts.map +1 -1
- package/dist/editor/canvas/GridViewer.d.ts +7 -3
- package/dist/editor/canvas/GridViewer.d.ts.map +1 -1
- package/dist/editor/canvas/TwoColumnDesigner.d.ts.map +1 -1
- package/dist/editor/canvas/canvasTranslations.d.ts +6 -0
- package/dist/editor/canvas/canvasTranslations.d.ts.map +1 -1
- package/dist/editor/document/constants.d.ts +0 -15
- package/dist/editor/document/constants.d.ts.map +1 -1
- package/dist/editor/document/utils.d.ts +0 -15
- package/dist/editor/document/utils.d.ts.map +1 -1
- package/dist/editor/index.d.ts +1 -0
- package/dist/editor/index.d.ts.map +1 -1
- package/dist/editor/sidebar/form/ComponentEditorForm.d.ts.map +1 -1
- package/dist/editor/sidebar/form/fieldRendererUtils.d.ts +3 -1
- package/dist/editor/sidebar/form/fieldRendererUtils.d.ts.map +1 -1
- package/dist/editor/sidebar/form/fieldRenderers.d.ts.map +1 -1
- package/dist/editor/sidebar/form/formTranslations.d.ts +4 -0
- package/dist/editor/sidebar/form/formTranslations.d.ts.map +1 -1
- package/dist/editor/sidebar/form/renderers/AltTextFieldRenderer.d.ts +1 -1
- package/dist/editor/sidebar/form/renderers/AltTextFieldRenderer.d.ts.map +1 -1
- package/dist/editor/sidebar/form/renderers/AnswerArrayFieldRenderer.d.ts +1 -1
- package/dist/editor/sidebar/form/renderers/AnswerArrayFieldRenderer.d.ts.map +1 -1
- package/dist/editor/sidebar/form/renderers/ObjectArrayFieldRenderer.d.ts +1 -1
- package/dist/editor/sidebar/form/renderers/ObjectArrayFieldRenderer.d.ts.map +1 -1
- package/dist/editor/sidebar/form/uploaders/FileUploader.d.ts +3 -1
- package/dist/editor/sidebar/form/uploaders/FileUploader.d.ts.map +1 -1
- package/dist/editor/sidebar/form/uploaders/ImageUploader.d.ts +2 -1
- package/dist/editor/sidebar/form/uploaders/ImageUploader.d.ts.map +1 -1
- package/dist/editor/sidebar/form/uploaders/VideoUploader.d.ts +2 -1
- package/dist/editor/sidebar/form/uploaders/VideoUploader.d.ts.map +1 -1
- package/dist/editor/sidebar/panel/types.d.ts +2 -1
- package/dist/editor/sidebar/panel/types.d.ts.map +1 -1
- package/dist/editor/sidebar/sidebarTranslations.d.ts +4 -0
- package/dist/editor/sidebar/sidebarTranslations.d.ts.map +1 -1
- package/dist/editor/sidebar/tray/BlockTray.d.ts.map +1 -1
- package/dist/editor/state/editorAccess.d.ts +14 -0
- package/dist/editor/state/editorAccess.d.ts.map +1 -0
- package/dist/editor/validation/templateDataValidator.d.ts +1 -14
- package/dist/editor/validation/templateDataValidator.d.ts.map +1 -1
- package/dist/index.js +6913 -6779
- package/dist/schema/schemaRegistry.d.ts +16 -16
- package/locales/en.json +7 -0
- package/package.json +29 -28
- package/dist/editor/ai/isBlockEmpty.test.d.ts +0 -2
- package/dist/editor/ai/isBlockEmpty.test.d.ts.map +0 -1
- package/dist/editor/ai/isItemEmpty.test.d.ts +0 -2
- package/dist/editor/ai/isItemEmpty.test.d.ts.map +0 -1
- package/dist/editor/ai/previewDiff.test.d.ts +0 -2
- package/dist/editor/ai/previewDiff.test.d.ts.map +0 -1
- package/dist/editor/document/utils.test.d.ts +0 -2
- package/dist/editor/document/utils.test.d.ts.map +0 -1
- package/dist/editor/history/undoRedoManager.test.d.ts +0 -2
- package/dist/editor/history/undoRedoManager.test.d.ts.map +0 -1
- package/dist/editor/history/useUndoRedo.test.d.ts +0 -2
- package/dist/editor/history/useUndoRedo.test.d.ts.map +0 -1
- package/dist/editor/state/applyTemplatePatch.test.d.ts +0 -2
- package/dist/editor/state/applyTemplatePatch.test.d.ts.map +0 -1
- package/dist/editor/state/blockDataStore.test.d.ts +0 -2
- package/dist/editor/state/blockDataStore.test.d.ts.map +0 -1
- package/dist/editor/state/useBlockEditorState.test.d.ts +0 -2
- package/dist/editor/state/useBlockEditorState.test.d.ts.map +0 -1
- package/dist/editor/state/useUndoRedoState.test.d.ts +0 -2
- package/dist/editor/state/useUndoRedoState.test.d.ts.map +0 -1
- package/dist/editor/validation/templateDataValidator.test.d.ts +0 -2
- package/dist/editor/validation/templateDataValidator.test.d.ts.map +0 -1
- package/dist/registry/registryTypes.test.d.ts +0 -1
- package/dist/registry/registryTypes.test.d.ts.map +0 -1
- package/dist/registry/templateLayoutSchema.test.d.ts +0 -2
- package/dist/registry/templateLayoutSchema.test.d.ts.map +0 -1
- package/dist/schema/schemaRegistry.test.d.ts +0 -2
- package/dist/schema/schemaRegistry.test.d.ts.map +0 -1
- package/dist/schema/zodUtils.test.d.ts +0 -2
- package/dist/schema/zodUtils.test.d.ts.map +0 -1
- package/dist/utils/colorVariants/brandColorVariants.test.d.ts +0 -2
- package/dist/utils/colorVariants/brandColorVariants.test.d.ts.map +0 -1
- package/dist/utils/colorVariants/color.test.d.ts +0 -2
- package/dist/utils/colorVariants/color.test.d.ts.map +0 -1
- package/dist/utils/colorVariants/deriveColorVariants.test.d.ts +0 -2
- package/dist/utils/colorVariants/deriveColorVariants.test.d.ts.map +0 -1
- package/dist/utils/safeMediaUrl.test.d.ts +0 -2
- package/dist/utils/safeMediaUrl.test.d.ts.map +0 -1
package/README.md
CHANGED
|
@@ -116,6 +116,21 @@ tool from the sidebar waits for `proceed()`. A tool's `background` and `bodyBack
|
|
|
116
116
|
panel and body fills (any CSS `background`, gradients included); `variant: 'dark-surface'` sets the
|
|
117
117
|
light-on-dark header.
|
|
118
118
|
|
|
119
|
+
**Access.** Pass `access` to limit what the author may change. It can change at any time without a
|
|
120
|
+
remount:
|
|
121
|
+
|
|
122
|
+
- `editable` (the default): everything.
|
|
123
|
+
- `content-only`: the layout is locked. Blocks can't be added, removed, reordered, or duplicated,
|
|
124
|
+
but their settings stay editable.
|
|
125
|
+
- `read-only`: nothing changes. Selecting a block opens its settings read-only, and AI is hidden.
|
|
126
|
+
|
|
127
|
+
Your injected RCE receives `readOnly`, so forward it to your editor, or rich text stays editable.
|
|
128
|
+
Access only gates the editor UI. Gate your own Undo, Redo, and Save controls, and enforce
|
|
129
|
+
permissions on the server. `DesignerArea` and `GridDndProvider` take the same prop.
|
|
130
|
+
|
|
131
|
+
**Empty document.** Pass `emptyState` to show your own message on the canvas while the document has
|
|
132
|
+
no blocks, for example copy that fits the author's access.
|
|
133
|
+
|
|
119
134
|
### Or compose the primitives yourself
|
|
120
135
|
|
|
121
136
|
Every arrangement above is reproducible. Wrap your own layout in one `GridDndProvider` and drop a
|
|
@@ -211,7 +226,7 @@ Blocks and the editor read only from context; the host provides the implementati
|
|
|
211
226
|
| `BrandColorContext` | the brand color (hex/`rgb()`), or `undefined` |
|
|
212
227
|
| `BlockTranslationsProvider` | resolved strings per block + designer chrome (bundled English is the fallback) |
|
|
213
228
|
| `RichTextRendererContext` | a renderer for RCE-authored HTML (read path); unset → sanitized fallback |
|
|
214
|
-
| `RichTextEditorContext` | the RCE editor component (write path); unset → plain `TextArea`. An RCE with overlays that portal outside the editor also needs `BlockContentEditor`'s `isEditorOverlayOpen` (see Write path) |
|
|
229
|
+
| `RichTextEditorContext` | the RCE editor component (write path); unset → plain `TextArea`. It receives `readOnly` in a read-only editor. An RCE with overlays that portal outside the editor also needs `BlockContentEditor`'s `isEditorOverlayOpen` (see Write path) |
|
|
215
230
|
| `AIActionContext` | the AI executor; **presence enables** the block-level AI, unset → hidden |
|
|
216
231
|
| `BlockEditorApiProvider` | host data hooks — image/video/widget URLs and the settings-form file upload/delete |
|
|
217
232
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { View } from '@instructure/ui-view';
|
|
1
|
+
import { View } from '@instructure/ui-view/latest';
|
|
2
2
|
import { ComponentProps } from 'react';
|
|
3
3
|
type ViewProps = ComponentProps<typeof View>;
|
|
4
4
|
export type MediaPlaceholderVariant = 'empty' | 'loading' | 'error' | 'processing';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MediaPlaceholder.d.ts","sourceRoot":"","sources":["../../../src/components/MediaPlaceholder/MediaPlaceholder.tsx"],"names":[],"mappings":"AAoBA,OAAO,EAAE,IAAI,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"MediaPlaceholder.d.ts","sourceRoot":"","sources":["../../../src/components/MediaPlaceholder/MediaPlaceholder.tsx"],"names":[],"mappings":"AAoBA,OAAO,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAA;AAClD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAG3C,KAAK,SAAS,GAAG,cAAc,CAAC,OAAO,IAAI,CAAC,CAAA;AAE5C,MAAM,MAAM,uBAAuB,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,GAAG,YAAY,CAAA;AAElF,MAAM,WAAW,qBAAqB;IACpC;;;;OAIG;IACH,IAAI,EAAE,MAAM,CAAA;IACZ,qEAAqE;IACrE,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,OAAO,CAAC,EAAE,uBAAuB,CAAA;IACjC,yEAAyE;IACzE,YAAY,CAAC,EAAE,SAAS,CAAC,cAAc,CAAC,CAAA;CACzC;AAED;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,IAAI,EACJ,QAAQ,EACR,OAAiB,EACjB,YAAuB,GACxB,EAAE,qBAAqB,2CA2CvB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Accordion.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/Accordion/Accordion.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Accordion.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/Accordion/Accordion.tsx"],"names":[],"mappings":"AA+BA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAA;AAe5D,gGAAgG;AAChG,wBAAgB,SAAS,CAAC,EACxB,KAAK,EACL,OAAc,EACd,cAAc,EACd,KAAU,EACV,cAA0B,EAC1B,UAAoB,EACpB,UAAwB,EACxB,WAAuB,EACvB,iBAA0B,EAC1B,iBAA0B,EAC1B,aAAa,GACd,EAAE,cAAc,2CA4KhB"}
|
|
@@ -8,12 +8,12 @@ export declare const AccordionItemSchema: z.ZodObject<{
|
|
|
8
8
|
title: z.ZodString;
|
|
9
9
|
content: z.ZodString;
|
|
10
10
|
}, "strip", z.ZodTypeAny, {
|
|
11
|
-
id: string;
|
|
12
11
|
title: string;
|
|
12
|
+
id: string;
|
|
13
13
|
content: string;
|
|
14
14
|
}, {
|
|
15
|
-
id: string;
|
|
16
15
|
title: string;
|
|
16
|
+
id: string;
|
|
17
17
|
content: string;
|
|
18
18
|
}>;
|
|
19
19
|
export declare const AccordionPropsSchema: z.ZodObject<{
|
|
@@ -25,12 +25,12 @@ export declare const AccordionPropsSchema: z.ZodObject<{
|
|
|
25
25
|
title: z.ZodString;
|
|
26
26
|
content: z.ZodString;
|
|
27
27
|
}, "strip", z.ZodTypeAny, {
|
|
28
|
-
id: string;
|
|
29
28
|
title: string;
|
|
29
|
+
id: string;
|
|
30
30
|
content: string;
|
|
31
31
|
}, {
|
|
32
|
-
id: string;
|
|
33
32
|
title: string;
|
|
33
|
+
id: string;
|
|
34
34
|
content: string;
|
|
35
35
|
}>, "many">;
|
|
36
36
|
accordionStyle: z.ZodOptional<z.ZodDefault<z.ZodEnum<["outline", "solid"]>>>;
|
|
@@ -41,8 +41,8 @@ export declare const AccordionPropsSchema: z.ZodObject<{
|
|
|
41
41
|
dropdownDirection: z.ZodOptional<z.ZodDefault<z.ZodEnum<["down", "center"]>>>;
|
|
42
42
|
}, "strip", z.ZodTypeAny, {
|
|
43
43
|
items: {
|
|
44
|
-
id: string;
|
|
45
44
|
title: string;
|
|
45
|
+
id: string;
|
|
46
46
|
content: string;
|
|
47
47
|
}[];
|
|
48
48
|
title?: string | undefined;
|
|
@@ -56,8 +56,8 @@ export declare const AccordionPropsSchema: z.ZodObject<{
|
|
|
56
56
|
dropdownDirection?: "center" | "down" | undefined;
|
|
57
57
|
}, {
|
|
58
58
|
items: {
|
|
59
|
-
id: string;
|
|
60
59
|
title: string;
|
|
60
|
+
id: string;
|
|
61
61
|
content: string;
|
|
62
62
|
}[];
|
|
63
63
|
title?: string | undefined;
|
|
@@ -92,8 +92,8 @@ export type AccordionDropdownDirection = z.infer<typeof AccordionDropdownDirecti
|
|
|
92
92
|
export declare const AccordionDefaultProps: AccordionProps;
|
|
93
93
|
export declare const RegisteredAccordionPropsSchema: import('../../..').RegisteredComponentSchema<{
|
|
94
94
|
items: {
|
|
95
|
-
id: string;
|
|
96
95
|
title: string;
|
|
96
|
+
id: string;
|
|
97
97
|
content: string;
|
|
98
98
|
}[];
|
|
99
99
|
title?: string | undefined;
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
*/
|
|
6
6
|
export declare const createAccordionBlock: (options: import('../../..').BlockFactoryOptions<import('./accordionTranslations').AccordionTranslations>) => import('../../..').BlockRegistryEntry<{
|
|
7
7
|
items: {
|
|
8
|
-
id: string;
|
|
9
8
|
title: string;
|
|
9
|
+
id: string;
|
|
10
10
|
content: string;
|
|
11
11
|
}[];
|
|
12
12
|
title?: string | undefined;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { Flex } from '@instructure/ui-flex';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
import { Flex } from '@instructure/ui-flex/latest';
|
|
2
|
+
import { ChevronDownInstUIIcon } from '@instructure/ui-icons';
|
|
3
|
+
import { ToggleDetails } from '@instructure/ui-toggle-details/latest';
|
|
4
|
+
import { View } from '@instructure/ui-view/latest';
|
|
5
|
+
import { ComponentProps } from 'react';
|
|
5
6
|
import { ColorTheme, CornerStyle } from '../commonSchemas';
|
|
6
7
|
import { AccordionConnection, AccordionDropdownDirection, AccordionDropdownPlacement, AccordionStyle } from './accordionPropsSchema';
|
|
7
8
|
type ViewProps = ComponentProps<typeof View>;
|
|
@@ -24,10 +25,12 @@ export interface AccordionViewProps {
|
|
|
24
25
|
* — `ic-brand-primary` in the canvas theme — so on a filled header the default ring is
|
|
25
26
|
* invisible for every host, whatever brand color they set, and for the tints derived
|
|
26
27
|
* from it. A filled surface therefore rings with `focusColor="inverse"`, which the
|
|
27
|
-
* canvas theme leaves alone, or with the accessible color already
|
|
28
|
-
* surface once a host brand color applies.
|
|
28
|
+
* canvas theme leaves alone, or with `focusRingColor`, the accessible color already
|
|
29
|
+
* paired with that surface once a host brand color applies.
|
|
29
30
|
*/
|
|
30
|
-
header: Pick<ViewProps, 'padding' | 'focusColor'
|
|
31
|
+
header: Pick<ViewProps, 'padding' | 'focusColor'> & {
|
|
32
|
+
focusRingColor?: string;
|
|
33
|
+
};
|
|
31
34
|
content: Pick<ViewProps, 'background' | 'borderColor' | 'borderWidth' | 'padding' | 'themeOverride'>;
|
|
32
35
|
toggle: ToggleDetailsThemeOverride;
|
|
33
36
|
}
|
|
@@ -41,8 +44,7 @@ export interface AccordionItemLayout {
|
|
|
41
44
|
contentBorderRadius: NonNullable<ViewProps['borderRadius']>;
|
|
42
45
|
/**
|
|
43
46
|
* The item's top corners. Applied to the header row while its panel is open so the
|
|
44
|
-
* focus ring follows them — a CSS outline traces its element's `border-radius
|
|
45
|
-
* `View`'s own `focusRingBorderRadius` is declared but unimplemented in InstUI 11.6.
|
|
47
|
+
* focus ring follows them — a CSS outline traces its element's `border-radius`.
|
|
46
48
|
*/
|
|
47
49
|
headerBorderRadius: NonNullable<ViewProps['borderRadius']>;
|
|
48
50
|
}
|
|
@@ -57,8 +59,8 @@ export declare function getAccordionItemLayout({ index, count, connection, corne
|
|
|
57
59
|
* CSS; swapping InstUI icons gets the same result with no raw CSS.
|
|
58
60
|
*/
|
|
59
61
|
export declare function getAccordionIcons(direction: AccordionDropdownDirection): {
|
|
60
|
-
closedIcon:
|
|
61
|
-
openIcon:
|
|
62
|
+
closedIcon: typeof ChevronDownInstUIIcon;
|
|
63
|
+
openIcon: typeof ChevronDownInstUIIcon;
|
|
62
64
|
};
|
|
63
65
|
/** Row order for the header: the chevron trails the title, or leads it. */
|
|
64
66
|
export declare function getAccordionHeaderDirection(placement: AccordionDropdownPlacement): NonNullable<ComponentProps<typeof Flex>['direction']>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getAccordionViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/Accordion/getAccordionViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"getAccordionViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/Accordion/getAccordionViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAA;AACvD,OAAO,EACL,qBAAqB,EAGtB,MAAM,uBAAuB,CAAA;AAC9B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,uCAAuC,CAAA;AAC1E,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAA;AACvD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAE3C,OAAO,KAAK,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAC/D,OAAO,KAAK,EACV,mBAAmB,EACnB,0BAA0B,EAC1B,0BAA0B,EAC1B,cAAc,EACf,MAAM,wBAAwB,CAAA;AAE/B,KAAK,SAAS,GAAG,cAAc,CAAC,OAAO,IAAI,CAAC,CAAA;AAC5C,KAAK,kBAAkB,GAAG,cAAc,CAAC,OAAO,aAAa,CAAC,CAAA;AAC9D,KAAK,0BAA0B,GAAG,kBAAkB,CAAC,eAAe,CAAC,CA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0B,GAAG;IACxE,UAAU,EAAE,OAAO,qBAAqB,CAAA;IACxC,QAAQ,EAAE,OAAO,qBAAqB,CAAA;CACvC,CAIA;AAED,2EAA2E;AAC3E,wBAAgB,2BAA2B,CACzC,SAAS,EAAE,0BAA0B,GACpC,WAAW,CAAC,cAAc,CAAC,OAAO,IAAI,CAAC,CAAC,WAAW,CAAC,CAAC,CAEvD"}
|
|
@@ -22,12 +22,12 @@ export declare const BannerPropsSchema: z.ZodObject<{
|
|
|
22
22
|
}, "strip", z.ZodTypeAny, {
|
|
23
23
|
title: string;
|
|
24
24
|
variant: "h2" | "h3" | "h4";
|
|
25
|
+
style?: "image" | "none" | "outline" | "solid" | undefined;
|
|
26
|
+
color?: "light" | "dark" | "neutral" | undefined;
|
|
25
27
|
content?: string | undefined;
|
|
26
28
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
27
29
|
alt?: string | undefined;
|
|
28
|
-
|
|
29
|
-
color?: "light" | "dark" | "neutral" | undefined;
|
|
30
|
-
align?: "left" | "center" | "right" | undefined;
|
|
30
|
+
align?: "center" | "left" | "right" | undefined;
|
|
31
31
|
subtitle?: string | undefined;
|
|
32
32
|
eyebrowStyle?: "all-caps" | "sentence-case" | "capitalized" | undefined;
|
|
33
33
|
imagePlacement?: "background" | "above" | "below" | undefined;
|
|
@@ -35,13 +35,13 @@ export declare const BannerPropsSchema: z.ZodObject<{
|
|
|
35
35
|
isDecorative?: boolean | undefined;
|
|
36
36
|
}, {
|
|
37
37
|
title: string;
|
|
38
|
+
style?: "image" | "none" | "outline" | "solid" | undefined;
|
|
39
|
+
color?: "light" | "dark" | "neutral" | undefined;
|
|
38
40
|
content?: string | undefined;
|
|
39
41
|
variant?: "h2" | "h3" | "h4" | undefined;
|
|
40
42
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
41
43
|
alt?: string | undefined;
|
|
42
|
-
|
|
43
|
-
color?: "light" | "dark" | "neutral" | undefined;
|
|
44
|
-
align?: "left" | "center" | "right" | undefined;
|
|
44
|
+
align?: "center" | "left" | "right" | undefined;
|
|
45
45
|
subtitle?: string | undefined;
|
|
46
46
|
eyebrowStyle?: "all-caps" | "sentence-case" | "capitalized" | undefined;
|
|
47
47
|
imagePlacement?: "background" | "above" | "below" | undefined;
|
|
@@ -56,12 +56,12 @@ export declare const BannerDefaultProps: BannerProps;
|
|
|
56
56
|
export declare const RegisteredBannerPropsSchema: import('../../..').RegisteredComponentSchema<{
|
|
57
57
|
title: string;
|
|
58
58
|
variant: "h2" | "h3" | "h4";
|
|
59
|
+
style?: "image" | "none" | "outline" | "solid" | undefined;
|
|
60
|
+
color?: "light" | "dark" | "neutral" | undefined;
|
|
59
61
|
content?: string | undefined;
|
|
60
62
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
61
63
|
alt?: string | undefined;
|
|
62
|
-
|
|
63
|
-
color?: "light" | "dark" | "neutral" | undefined;
|
|
64
|
-
align?: "left" | "center" | "right" | undefined;
|
|
64
|
+
align?: "center" | "left" | "right" | undefined;
|
|
65
65
|
subtitle?: string | undefined;
|
|
66
66
|
eyebrowStyle?: "all-caps" | "sentence-case" | "capitalized" | undefined;
|
|
67
67
|
imagePlacement?: "background" | "above" | "below" | undefined;
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
export declare const createBannerBlock: (options: import('../../..').BlockFactoryOptions<import('./bannerTranslations').BannerTranslations>) => import('../../..').BlockRegistryEntry<{
|
|
7
7
|
title: string;
|
|
8
8
|
variant: "h2" | "h3" | "h4";
|
|
9
|
+
style?: "image" | "none" | "outline" | "solid" | undefined;
|
|
10
|
+
color?: "light" | "dark" | "neutral" | undefined;
|
|
9
11
|
content?: string | undefined;
|
|
10
12
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
11
13
|
alt?: string | undefined;
|
|
12
|
-
|
|
13
|
-
color?: "light" | "dark" | "neutral" | undefined;
|
|
14
|
-
align?: "left" | "center" | "right" | undefined;
|
|
14
|
+
align?: "center" | "left" | "right" | undefined;
|
|
15
15
|
subtitle?: string | undefined;
|
|
16
16
|
eyebrowStyle?: "all-caps" | "sentence-case" | "capitalized" | undefined;
|
|
17
17
|
imagePlacement?: "background" | "above" | "below" | undefined;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Text as UIText } from '@instructure/ui-text';
|
|
2
|
-
import { View } from '@instructure/ui-view';
|
|
1
|
+
import { Text as UIText } from '@instructure/ui-text/latest';
|
|
2
|
+
import { View } from '@instructure/ui-view/latest';
|
|
3
3
|
import { ComponentProps } from 'react';
|
|
4
4
|
import { BlockRenderProps } from '../brandTheming';
|
|
5
5
|
import { Align, ColorTheme, CornerStyle } from '../commonSchemas';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getBannerViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/Banner/getBannerViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,IAAI,MAAM,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"getBannerViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/Banner/getBannerViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,IAAI,MAAM,EAAE,MAAM,6BAA6B,CAAA;AACjE,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAA;AACvD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,EAAE,KAAK,gBAAgB,EAAiB,MAAM,iBAAiB,CAAA;AACtE,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAEtE,OAAO,KAAK,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAA;AAEhG,KAAK,SAAS,GAAG,cAAc,CAAC,OAAO,IAAI,CAAC,CAAA;AAC5C,KAAK,WAAW,GAAG,cAAc,CAAC,OAAO,MAAM,CAAC,CAAA;AAEhD,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,12 @@ export declare const CodeBlockPropsSchema: z.ZodObject<{
|
|
|
8
8
|
}, "strip", z.ZodTypeAny, {
|
|
9
9
|
code: string;
|
|
10
10
|
language: "html" | "text" | "javascript" | "json" | "css" | "bash" | "yaml";
|
|
11
|
-
cornerStyle?: "rounded" | "square" | undefined;
|
|
12
11
|
header?: string | undefined;
|
|
12
|
+
cornerStyle?: "rounded" | "square" | undefined;
|
|
13
13
|
}, {
|
|
14
14
|
code: string;
|
|
15
|
-
cornerStyle?: "rounded" | "square" | undefined;
|
|
16
15
|
header?: string | undefined;
|
|
16
|
+
cornerStyle?: "rounded" | "square" | undefined;
|
|
17
17
|
language?: unknown;
|
|
18
18
|
}>;
|
|
19
19
|
export type CodeBlockProps = z.infer<typeof CodeBlockPropsSchema>;
|
|
@@ -22,7 +22,7 @@ export declare const CodeBlockDefaultProps: CodeBlockProps;
|
|
|
22
22
|
export declare const RegisteredCodeBlockPropsSchema: import('../../..').RegisteredComponentSchema<{
|
|
23
23
|
code: string;
|
|
24
24
|
language: "html" | "text" | "javascript" | "json" | "css" | "bash" | "yaml";
|
|
25
|
-
cornerStyle?: "rounded" | "square" | undefined;
|
|
26
25
|
header?: string | undefined;
|
|
26
|
+
cornerStyle?: "rounded" | "square" | undefined;
|
|
27
27
|
}>;
|
|
28
28
|
//# sourceMappingURL=codeBlockPropsSchema.d.ts.map
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
export declare const createCodeBlock: (options: import('../../..').BlockFactoryOptions<import('./codeBlockTranslations').CodeBlockTranslations>) => import('../../..').BlockRegistryEntry<{
|
|
7
7
|
code: string;
|
|
8
8
|
language: "html" | "text" | "javascript" | "json" | "css" | "bash" | "yaml";
|
|
9
|
-
cornerStyle?: "rounded" | "square" | undefined;
|
|
10
9
|
header?: string | undefined;
|
|
10
|
+
cornerStyle?: "rounded" | "square" | undefined;
|
|
11
11
|
}>;
|
|
12
12
|
//# sourceMappingURL=createCodeBlock.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getCodeBlockViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/CodeBlock/getCodeBlockViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"getCodeBlockViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/CodeBlock/getCodeBlockViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAA;AACvD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAEnD,KAAK,SAAS,GAAG,cAAc,CAAC,OAAO,IAAI,CAAC,CAAA;AAE5C,2EAA2E;AAC3E,MAAM,WAAW,kBAAkB;IACjC,UAAU,EAAE,WAAW,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,CAAA;IAChD,YAAY,EAAE,WAAW,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC,CAAA;IACpD,OAAO,EAAE,SAAS,CAAC,SAAS,CAAC,CAAA;CAC9B;AAED,wBAAgB,qBAAqB,CAAC,WAAW,EAAE,WAAW,GAAG,kBAAkB,CAMlF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getFlashCardsViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/FlashCards/getFlashCardsViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"getFlashCardsViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/FlashCards/getFlashCardsViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAA;AACvD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,EAAE,KAAK,gBAAgB,EAAiB,MAAM,iBAAiB,CAAA;AACtE,OAAO,KAAK,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAG/D,KAAK,SAAS,GAAG,cAAc,CAAC,OAAO,IAAI,CAAC,CAAA;AAE5C;;;GAGG;AACH,MAAM,WAAW,kBAAkB;IACjC,UAAU,EAAE,WAAW,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,CAAA;IAChD,MAAM,EAAE,SAAS,CAAC,QAAQ,CAAC,CAAA;IAC3B,YAAY,EAAE,WAAW,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC,CAAA;IACpD,OAAO,EAAE,SAAS,CAAC,SAAS,CAAC,CAAA;CAC9B;AAED,MAAM,WAAW,mBAAmB;IAClC,SAAS,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAA;IACnC,IAAI,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAA;IAC9B,IAAI,EAAE,kBAAkB,CAAA;CACzB;AAED,wBAAgB,sBAAsB,CACpC,UAAU,EAAE,UAAU,EACtB,WAAW,EAAE,WAAW,EACxB,UAAU,CAAC,EAAE,MAAM,GAClB,mBAAmB,CAerB"}
|
|
@@ -6,10 +6,10 @@
|
|
|
6
6
|
export declare const createImageBlock: (options: import('../../..').BlockFactoryOptions<import('./imageBlockTranslations').ImageBlockTranslations>) => import('../../..').BlockRegistryEntry<{
|
|
7
7
|
alt: string;
|
|
8
8
|
size: number;
|
|
9
|
-
align: "
|
|
9
|
+
align: "center" | "left" | "right";
|
|
10
10
|
asset_id: string;
|
|
11
11
|
isDecorative: boolean;
|
|
12
|
-
ratio: "
|
|
12
|
+
ratio: "circle" | "square" | "landscape" | "portrait";
|
|
13
13
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
14
14
|
}>;
|
|
15
15
|
//# sourceMappingURL=createImageBlock.d.ts.map
|
|
@@ -11,19 +11,19 @@ export declare const ImageBlockPropsSchema: z.ZodObject<{
|
|
|
11
11
|
}, "strip", z.ZodTypeAny, {
|
|
12
12
|
alt: string;
|
|
13
13
|
size: number;
|
|
14
|
-
align: "
|
|
14
|
+
align: "center" | "left" | "right";
|
|
15
15
|
asset_id: string;
|
|
16
16
|
isDecorative: boolean;
|
|
17
|
-
ratio: "
|
|
17
|
+
ratio: "circle" | "square" | "landscape" | "portrait";
|
|
18
18
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
19
19
|
}, {
|
|
20
20
|
alt: string;
|
|
21
21
|
asset_id: string;
|
|
22
22
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
23
23
|
size?: number | undefined;
|
|
24
|
-
align?: "
|
|
24
|
+
align?: "center" | "left" | "right" | undefined;
|
|
25
25
|
isDecorative?: boolean | undefined;
|
|
26
|
-
ratio?: "
|
|
26
|
+
ratio?: "circle" | "square" | "landscape" | "portrait" | undefined;
|
|
27
27
|
}>;
|
|
28
28
|
export type ImageBlockProps = z.infer<typeof ImageBlockPropsSchema>;
|
|
29
29
|
export type ImageRatio = z.infer<typeof ImageRatioSchema>;
|
|
@@ -31,10 +31,10 @@ export declare const ImageBlockDefaultProps: ImageBlockProps;
|
|
|
31
31
|
export declare const RegisteredImageBlockPropsSchema: import('../../..').RegisteredComponentSchema<{
|
|
32
32
|
alt: string;
|
|
33
33
|
size: number;
|
|
34
|
-
align: "
|
|
34
|
+
align: "center" | "left" | "right";
|
|
35
35
|
asset_id: string;
|
|
36
36
|
isDecorative: boolean;
|
|
37
|
-
ratio: "
|
|
37
|
+
ratio: "circle" | "square" | "landscape" | "portrait";
|
|
38
38
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
39
39
|
}>;
|
|
40
40
|
//# sourceMappingURL=imageBlockPropsSchema.d.ts.map
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Makes the focus ring of the `View` inside it follow `focusPosition="inset"`. InstUI's
|
|
4
|
+
* inset offset is `0`, which draws the ring just outside the element's edge. A negative
|
|
5
|
+
* offset the width of the ring pulls it inside, over the element's own surface.
|
|
6
|
+
*
|
|
7
|
+
* `color` recolors the ring for a surface that swallows InstUI's default (the brand color).
|
|
8
|
+
* Wrap only the focusable `View`: the override reaches every focusable descendant too.
|
|
9
|
+
*/
|
|
10
|
+
export declare function InsetFocusRing({ color, children }: {
|
|
11
|
+
color?: string;
|
|
12
|
+
children: ReactNode;
|
|
13
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
//# sourceMappingURL=InsetFocusRing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"InsetFocusRing.d.ts","sourceRoot":"","sources":["../../../src/components/blocks/InsetFocusRing.tsx"],"names":[],"mappings":"AAmBA,OAAO,EAAuB,KAAK,SAAS,EAAe,MAAM,OAAO,CAAA;AAsBxE;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE;IAAE,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,SAAS,CAAA;CAAE,2CAa1F"}
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
*/
|
|
6
6
|
export declare const createKnowledgeCheckBlock: (options: import('../../..').BlockFactoryOptions<import('./knowledgeCheckTranslations').KnowledgeCheckTranslations>) => import('../../..').BlockRegistryEntry<{
|
|
7
7
|
answers: {
|
|
8
|
-
id: string;
|
|
9
8
|
label: string;
|
|
9
|
+
id: string;
|
|
10
10
|
isCorrect: boolean;
|
|
11
11
|
}[];
|
|
12
12
|
question: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getKnowledgeCheckViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/KnowledgeCheck/getKnowledgeCheckViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"getKnowledgeCheckViewProps.d.ts","sourceRoot":"","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B,CAE5E;AAED,wBAAgB,0BAA0B,CACxC,WAAW,EAAE,WAAW,EACxB,WAAW,EAAE,WAAW,EACxB,UAAU,CAAC,EAAE,MAAM,GAClB,uBAAuB,CA4BzB"}
|
|
@@ -11,12 +11,12 @@ export declare const KnowledgeCheckAnswerSchema: z.ZodObject<{
|
|
|
11
11
|
label: z.ZodString;
|
|
12
12
|
isCorrect: z.ZodBoolean;
|
|
13
13
|
}, "strip", z.ZodTypeAny, {
|
|
14
|
-
id: string;
|
|
15
14
|
label: string;
|
|
15
|
+
id: string;
|
|
16
16
|
isCorrect: boolean;
|
|
17
17
|
}, {
|
|
18
|
-
id: string;
|
|
19
18
|
label: string;
|
|
19
|
+
id: string;
|
|
20
20
|
isCorrect: boolean;
|
|
21
21
|
}>;
|
|
22
22
|
export declare const KnowledgeCheckPropsSchema: z.ZodObject<{
|
|
@@ -28,20 +28,20 @@ export declare const KnowledgeCheckPropsSchema: z.ZodObject<{
|
|
|
28
28
|
label: z.ZodString;
|
|
29
29
|
isCorrect: z.ZodBoolean;
|
|
30
30
|
}, "strip", z.ZodTypeAny, {
|
|
31
|
-
id: string;
|
|
32
31
|
label: string;
|
|
32
|
+
id: string;
|
|
33
33
|
isCorrect: boolean;
|
|
34
34
|
}, {
|
|
35
|
-
id: string;
|
|
36
35
|
label: string;
|
|
36
|
+
id: string;
|
|
37
37
|
isCorrect: boolean;
|
|
38
38
|
}>, "many">;
|
|
39
39
|
headerStyle: z.ZodOptional<z.ZodDefault<z.ZodEnum<["none", "light", "dark"]>>>;
|
|
40
40
|
cornerStyle: z.ZodOptional<z.ZodDefault<z.ZodEnum<["rounded", "square"]>>>;
|
|
41
41
|
}, "strip", z.ZodTypeAny, {
|
|
42
42
|
answers: {
|
|
43
|
-
id: string;
|
|
44
43
|
label: string;
|
|
44
|
+
id: string;
|
|
45
45
|
isCorrect: boolean;
|
|
46
46
|
}[];
|
|
47
47
|
question: string;
|
|
@@ -51,8 +51,8 @@ export declare const KnowledgeCheckPropsSchema: z.ZodObject<{
|
|
|
51
51
|
headerStyle?: "light" | "dark" | "none" | undefined;
|
|
52
52
|
}, {
|
|
53
53
|
answers: {
|
|
54
|
-
id: string;
|
|
55
54
|
label: string;
|
|
55
|
+
id: string;
|
|
56
56
|
isCorrect: boolean;
|
|
57
57
|
}[];
|
|
58
58
|
question: string;
|
|
@@ -74,8 +74,8 @@ export type AnswerOrder = z.infer<typeof AnswerOrderSchema>;
|
|
|
74
74
|
export declare const KnowledgeCheckDefaultProps: KnowledgeCheckProps;
|
|
75
75
|
export declare const RegisteredKnowledgeCheckPropsSchema: import('../../..').RegisteredComponentSchema<{
|
|
76
76
|
answers: {
|
|
77
|
-
id: string;
|
|
78
77
|
label: string;
|
|
78
|
+
id: string;
|
|
79
79
|
isCorrect: boolean;
|
|
80
80
|
}[];
|
|
81
81
|
question: string;
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import { MatchCardState, MatchCardViewProps } from './getMixAndMatchViewProps';
|
|
2
|
+
/** Beyond this a card stops being scannable next to its neighbours. */
|
|
3
|
+
export declare const MAX_CARD_CHARS = 100;
|
|
2
4
|
export interface MatchCardProps {
|
|
3
5
|
text: string;
|
|
4
6
|
state: MatchCardState;
|
|
@@ -17,5 +19,5 @@ export interface MatchCardProps {
|
|
|
17
19
|
onClick: () => void;
|
|
18
20
|
elementRef?: (element: HTMLElement | null) => void;
|
|
19
21
|
}
|
|
20
|
-
export declare function MatchCard({ text, state, matched, card, disabled, ariaDisabled, label, pressed, onClick, elementRef, }: MatchCardProps): import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
export declare function MatchCard({ text, state, matched, card: { focusRingColor, ...card }, disabled, ariaDisabled, label, pressed, onClick, elementRef, }: MatchCardProps): import("react/jsx-runtime").JSX.Element;
|
|
21
23
|
//# sourceMappingURL=MatchCard.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MatchCard.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/MixAndMatch/MatchCard.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"MatchCard.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/MixAndMatch/MatchCard.tsx"],"names":[],"mappings":"AAsBA,OAAO,EAEL,KAAK,cAAc,EACnB,KAAK,kBAAkB,EACxB,MAAM,2BAA2B,CAAA;AAGlC,uEAAuE;AACvE,eAAO,MAAM,cAAc,MAAM,CAAA;AAEjC,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,MAAM,CAAA;IACZ,KAAK,EAAE,cAAc,CAAA;IACrB,OAAO,EAAE,OAAO,CAAA;IAChB,IAAI,EAAE,kBAAkB,CAAA;IACxB,QAAQ,EAAE,OAAO,CAAA;IACjB;;;OAGG;IACH,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,0DAA0D;IAC1D,KAAK,EAAE,MAAM,CAAA;IACb,6EAA6E;IAC7E,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,UAAU,CAAC,EAAE,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI,KAAK,IAAI,CAAA;CACnD;AAED,wBAAgB,SAAS,CAAC,EACxB,IAAI,EACJ,KAAK,EACL,OAAO,EACP,IAAI,EAAE,EAAE,cAAc,EAAE,GAAG,IAAI,EAAE,EACjC,QAAQ,EACR,YAAY,EACZ,KAAK,EACL,OAAO,EACP,OAAO,EACP,UAAU,GACX,EAAE,cAAc,2CAqChB"}
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import { MixAndMatchProps } from './mixAndMatchPropsSchema';
|
|
2
|
+
/** How long a correct pair stays highlighted before it fades out of the columns. */
|
|
3
|
+
export declare const CORRECT_HOLD_MS = 600;
|
|
4
|
+
/** How long a wrong pair stays flagged before both cards return to resting. */
|
|
5
|
+
export declare const INCORRECT_HOLD_MS = 1000;
|
|
2
6
|
/** A matching activity: pick a card on the left, then its partner on the right. */
|
|
3
7
|
export declare function MixAndMatch({ pairs, randomizeCards, colorTheme, cornerStyle, }: MixAndMatchProps): import("react/jsx-runtime").JSX.Element | null;
|
|
4
8
|
//# sourceMappingURL=MixAndMatch.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MixAndMatch.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/MixAndMatch/MixAndMatch.tsx"],"names":[],"mappings":"AAsCA,OAAO,KAAK,EAAmB,gBAAgB,EAAkB,MAAM,0BAA0B,CAAA;
|
|
1
|
+
{"version":3,"file":"MixAndMatch.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/MixAndMatch/MixAndMatch.tsx"],"names":[],"mappings":"AAsCA,OAAO,KAAK,EAAmB,gBAAgB,EAAkB,MAAM,0BAA0B,CAAA;AAGjG,oFAAoF;AACpF,eAAO,MAAM,eAAe,MAAM,CAAA;AAElC,+EAA+E;AAC/E,eAAO,MAAM,iBAAiB,OAAO,CAAA;AAsHrC,mFAAmF;AACnF,wBAAgB,WAAW,CAAC,EAC1B,KAAU,EACV,cAAqB,EACrB,UAAoB,EACpB,WAAuB,GACxB,EAAE,gBAAgB,kDA2ClB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { View } from '@instructure/ui-view';
|
|
1
|
+
import { View } from '@instructure/ui-view/latest';
|
|
2
2
|
import { ComponentProps } from 'react';
|
|
3
3
|
import { BlockRenderProps } from '../brandTheming';
|
|
4
4
|
import { ColorTheme, CornerStyle } from '../commonSchemas';
|
|
@@ -19,8 +19,10 @@ export interface MatchCardViewProps {
|
|
|
19
19
|
shadow: ViewProps['shadow'];
|
|
20
20
|
borderRadius: NonNullable<ViewProps['borderRadius']>;
|
|
21
21
|
padding: ViewProps['padding'];
|
|
22
|
-
/** Recolors the card's brand-token
|
|
22
|
+
/** Recolors the card's brand-token border; set only when a host brand color applies. */
|
|
23
23
|
themeOverride?: ViewProps['themeOverride'];
|
|
24
|
+
/** Color of the card's focus ring; set only when a host brand color applies. */
|
|
25
|
+
focusRingColor?: string;
|
|
24
26
|
}
|
|
25
27
|
export interface MixAndMatchViewProps {
|
|
26
28
|
container: BlockRenderProps['view'];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getMixAndMatchViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/MixAndMatch/getMixAndMatchViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"getMixAndMatchViewProps.d.ts","sourceRoot":"","sources":["../../../../src/components/blocks/MixAndMatch/getMixAndMatchViewProps.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAA;AACvD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,EAAE,KAAK,gBAAgB,EAAsC,MAAM,iBAAiB,CAAA;AAC3F,OAAO,KAAK,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAG/D,KAAK,SAAS,GAAG,cAAc,CAAC,OAAO,IAAI,CAAC,CAAA;AAE5C,qEAAqE;AACrE,MAAM,MAAM,cAAc,GAAG,SAAS,GAAG,UAAU,GAAG,SAAS,GAAG,WAAW,CAAA;AAE7E,4CAA4C;AAC5C,MAAM,WAAW,eAAe;IAC9B,WAAW,EAAE,WAAW,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAA;IAClD,WAAW,EAAE,SAAS,CAAC,aAAa,CAAC,CAAA;CACtC;AAED;;;GAGG;AACH,MAAM,WAAW,kBAAkB;IACjC,UAAU,EAAE,WAAW,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC,CAAA;IAChD,MAAM,EAAE,SAAS,CAAC,QAAQ,CAAC,CAAA;IAC3B,YAAY,EAAE,WAAW,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC,CAAA;IACpD,OAAO,EAAE,SAAS,CAAC,SAAS,CAAC,CAAA;IAC7B,wFAAwF;IACxF,aAAa,CAAC,EAAE,SAAS,CAAC,eAAe,CAAC,CAAA;IAC1C,gFAAgF;IAChF,cAAc,CAAC,EAAE,MAAM,CAAA;CACxB;AAED,MAAM,WAAW,oBAAoB;IACnC,SAAS,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAA;IACnC,IAAI,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAA;IAC9B,IAAI,EAAE,kBAAkB,CAAA;IACxB;;;;;;OAMG;IACH,UAAU,EAAE,MAAM,GAAG,SAAS,CAAA;IAC9B,gEAAgE;IAChE,aAAa,EAAE,SAAS,GAAG,iBAAiB,CAAA;CAC7C;AAmBD,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,cAAc,GAAG,eAAe,CAEzE;AAED,wBAAgB,uBAAuB,CACrC,UAAU,EAAE,UAAU,EACtB,WAAW,EAAE,WAAW,EACxB,UAAU,CAAC,EAAE,MAAM,GAClB,oBAAoB,CAgCtB"}
|
|
@@ -7,7 +7,7 @@ export declare const createQuoteBlock: (options: import('../../..').BlockFactory
|
|
|
7
7
|
content: string;
|
|
8
8
|
colorTheme?: "light" | "dark" | "neutral" | undefined;
|
|
9
9
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
10
|
-
align?: "
|
|
10
|
+
align?: "center" | "left" | "right" | undefined;
|
|
11
11
|
author?: string | undefined;
|
|
12
12
|
quoteSize?: number | undefined;
|
|
13
13
|
decorationStyle?: "fill" | "none" | "sidebar" | undefined;
|
|
@@ -20,7 +20,7 @@ export declare const QuotePropsSchema: z.ZodObject<{
|
|
|
20
20
|
content: string;
|
|
21
21
|
colorTheme?: "light" | "dark" | "neutral" | undefined;
|
|
22
22
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
23
|
-
align?: "
|
|
23
|
+
align?: "center" | "left" | "right" | undefined;
|
|
24
24
|
author?: string | undefined;
|
|
25
25
|
quoteSize?: number | undefined;
|
|
26
26
|
decorationStyle?: "fill" | "none" | "sidebar" | undefined;
|
|
@@ -28,7 +28,7 @@ export declare const QuotePropsSchema: z.ZodObject<{
|
|
|
28
28
|
content: string;
|
|
29
29
|
colorTheme?: "light" | "dark" | "neutral" | undefined;
|
|
30
30
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
31
|
-
align?: "
|
|
31
|
+
align?: "center" | "left" | "right" | undefined;
|
|
32
32
|
author?: string | undefined;
|
|
33
33
|
quoteSize?: number | undefined;
|
|
34
34
|
decorationStyle?: "fill" | "none" | "sidebar" | undefined;
|
|
@@ -40,7 +40,7 @@ export declare const RegisteredQuotePropsSchema: import('../../..').RegisteredCo
|
|
|
40
40
|
content: string;
|
|
41
41
|
colorTheme?: "light" | "dark" | "neutral" | undefined;
|
|
42
42
|
cornerStyle?: "rounded" | "square" | undefined;
|
|
43
|
-
align?: "
|
|
43
|
+
align?: "center" | "left" | "right" | undefined;
|
|
44
44
|
author?: string | undefined;
|
|
45
45
|
quoteSize?: number | undefined;
|
|
46
46
|
decorationStyle?: "fill" | "none" | "sidebar" | undefined;
|