@cratis/scene.components 2.0.0 → 3.1.0
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/.storybook/preview.tsx +18 -22
- package/common/SceneTooltip.tsx +5 -1
- package/cratisComponentsPackage.ts +2 -0
- package/dist/cjs/common/SceneTooltip.js +3 -1
- package/dist/cjs/common/SceneTooltip.js.map +1 -1
- package/dist/cjs/cratisComponentsPackage.js +3 -1
- package/dist/cjs/cratisComponentsPackage.js.map +1 -1
- package/dist/esm/common/SceneTooltip.d.ts.map +1 -1
- package/dist/esm/common/SceneTooltip.js +3 -1
- package/dist/esm/common/SceneTooltip.js.map +1 -1
- package/dist/esm/cratisComponentsPackage.d.ts.map +1 -1
- package/dist/esm/cratisComponentsPackage.js +3 -1
- package/dist/esm/cratisComponentsPackage.js.map +1 -1
- package/dist/esm/editors/for_SceneObjectNavigationalBar/when_navigating_back_up_the_trail.js +1 -2
- package/dist/esm/editors/for_SceneObjectNavigationalBar/when_navigating_back_up_the_trail.js.map +1 -1
- package/dist/esm/tsconfig.tsbuildinfo +1 -1
- package/editors/for_SceneObjectNavigationalBar/when_navigating_back_up_the_trail.tsx +5 -11
- package/package.json +20 -16
package/.storybook/preview.tsx
CHANGED
|
@@ -6,11 +6,9 @@ import { CratisComponentsProvider } from '@cratis/components/Common';
|
|
|
6
6
|
|
|
7
7
|
// The stylesheet stack a `@cratis/components` component needs, in the order the layers resolve.
|
|
8
8
|
//
|
|
9
|
-
//
|
|
10
|
-
//
|
|
11
|
-
//
|
|
12
|
-
// custom properties at runtime, or a sheet that assigns the library's own `--cratis-*` tokens directly.
|
|
13
|
-
// This preview takes the second path - see the decorator below for why.
|
|
9
|
+
// Components 4 owns its own markup and styling outright - there is no PrimeReact underneath it any more,
|
|
10
|
+
// and so no preset and no `--p-*` values behind the tokens. A look is one thing now: a sheet that assigns
|
|
11
|
+
// the library's own `--cratis-*` tokens.
|
|
14
12
|
//
|
|
15
13
|
// `tokens` declares the `--cratis-*` layer every component stylesheet reads, `styles` is that component
|
|
16
14
|
// CSS plus the compiled Tailwind utilities and the vendored Allotment sheet `DataPage`'s split view needs,
|
|
@@ -20,35 +18,33 @@ import { CratisComponentsProvider } from '@cratis/components/Common';
|
|
|
20
18
|
import '@cratis/components/tokens';
|
|
21
19
|
import '@cratis/components/styles';
|
|
22
20
|
import '@cratis/components/theme';
|
|
21
|
+
// Components 4 renders an `Icon` given a string as `<i className={icon} />` - a consumer-owned icon font,
|
|
22
|
+
// whichever one the consumer happens to load. These stories demonstrate that with `pi pi-*`, so the
|
|
23
|
+
// preview loads primeicons to make them visible. It is a Storybook devDependency for exactly this reason
|
|
24
|
+
// and nothing in the package's own source reaches for it.
|
|
23
25
|
import 'primeicons/primeicons.css';
|
|
24
26
|
import '../theme/sceneTokenBridge.css';
|
|
25
27
|
|
|
26
28
|
// The baseline theme is scoped to a `cratis-theme` ancestor rather than to `:root`, so something has to
|
|
27
|
-
// carry the class. `<body>` rather than a wrapper inside each story, because
|
|
28
|
-
//
|
|
29
|
-
//
|
|
29
|
+
// carry the class. `<body>` rather than a wrapper inside each story, because overlays - dialogs, select
|
|
30
|
+
// panels, the filter panel - are portaled to `document.body`; a wrapper would leave every one of them
|
|
31
|
+
// outside the themed subtree and rendering unstyled.
|
|
30
32
|
document.body.classList.add('cratis-theme');
|
|
31
33
|
|
|
32
34
|
/**
|
|
33
|
-
* Every story renders inside `CratisComponentsProvider`,
|
|
34
|
-
* PrimeReact's. Without it the wrapped components fall back to PrimeReact's defaults rather than
|
|
35
|
-
* Cratis', so a story would be showing something subtly different from what an application renders -
|
|
36
|
-
* which defeats the point of having stories at all.
|
|
35
|
+
* Every story renders inside `CratisComponentsProvider`, so a story shows what an application shows.
|
|
37
36
|
*
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
41
|
-
*
|
|
42
|
-
*
|
|
43
|
-
*
|
|
44
|
-
* It is the right choice for these stories on its own terms too. The `--cratis-*` token layer is exactly
|
|
45
|
-
* what `theme/sceneTokenBridge.css` overrides, so a Scene theme visibly takes over from the baseline in
|
|
46
|
-
* the `Themed` story rather than from a preset's `--p-*` values one level further down the chain.
|
|
37
|
+
* Components 4 narrowed the provider to configuration the library itself owns - `locale` and `messages`.
|
|
38
|
+
* The renderer keys it used to carry (`license`, `theme`, `defaults`, `pt`, `ripple`, `unstyled`) existed
|
|
39
|
+
* to configure PrimeReact underneath, and there is no PrimeReact underneath any more. `unstyled` in
|
|
40
|
+
* particular is gone rather than defaulted: the imported `@cratis/components/theme` is the look now, and
|
|
41
|
+
* `theme/sceneTokenBridge.css` overrides its `--cratis-*` tokens directly, which is what lets the `Themed`
|
|
42
|
+
* story visibly take over from the baseline.
|
|
47
43
|
*/
|
|
48
44
|
const preview: Preview = {
|
|
49
45
|
decorators: [
|
|
50
46
|
Story => (
|
|
51
|
-
<CratisComponentsProvider value={{
|
|
47
|
+
<CratisComponentsProvider value={{ locale: 'en-US' }}>
|
|
52
48
|
<Story />
|
|
53
49
|
</CratisComponentsProvider>
|
|
54
50
|
),
|
package/common/SceneTooltip.tsx
CHANGED
|
@@ -22,7 +22,11 @@ export function SceneTooltip({ element, slots }: RegisteredComponentProps) {
|
|
|
22
22
|
position={unionProperty(element.properties, 'position', positions)}
|
|
23
23
|
disabled={booleanProperty(element.properties, 'disabled')}
|
|
24
24
|
>
|
|
25
|
-
{
|
|
25
|
+
{/* Components 4 takes a single focusable trigger, which it clones to attach its own
|
|
26
|
+
class and part attributes, and a Scene slot is a list. The span is that one element:
|
|
27
|
+
without it a slot holding anything other than exactly one node fails to type, and a
|
|
28
|
+
slot is authored content we cannot assume the shape of. */}
|
|
29
|
+
<span>{slots.content}</span>
|
|
26
30
|
</Tooltip>
|
|
27
31
|
);
|
|
28
32
|
}
|
|
@@ -90,6 +90,8 @@ export const cratisComponentsPackageManifest: ScenePackage = {
|
|
|
90
90
|
displayName: 'Cratis Components',
|
|
91
91
|
description: "Cratis' Arc-bound data, form and dialog composites, built on PrimeReact and Tailwind.",
|
|
92
92
|
module: '@cratis/scene.components',
|
|
93
|
+
license: 'MIT',
|
|
94
|
+
licenseUrl: 'https://github.com/Cratis/Scene/blob/main/LICENSE',
|
|
93
95
|
};
|
|
94
96
|
|
|
95
97
|
/**
|
|
@@ -21,7 +21,9 @@ var properties = require('../properties.js');
|
|
|
21
21
|
content: properties.stringProperty(element.properties, 'content') ?? '',
|
|
22
22
|
position: properties.unionProperty(element.properties, 'position', positions),
|
|
23
23
|
disabled: properties.booleanProperty(element.properties, 'disabled'),
|
|
24
|
-
children:
|
|
24
|
+
children: /*#__PURE__*/ jsxRuntime.jsx("span", {
|
|
25
|
+
children: slots.content
|
|
26
|
+
})
|
|
25
27
|
});
|
|
26
28
|
}
|
|
27
29
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SceneTooltip.js","sources":["../../../common/SceneTooltip.tsx"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { Tooltip } from '@cratis/components/Common';\nimport { RegisteredComponentProps } from '@cratis/scene.react';\nimport { booleanProperty, stringProperty, unionProperty } from '../properties';\n\n/** Which side of the wrapped content the tooltip appears on. */\nconst positions = ['top', 'right', 'bottom', 'left'] as const;\n\n/**\n * The `Cratis.Components:tooltip` component - `Tooltip` from `@cratis/components/Common`.\n *\n * Wraps whatever is in its `content` slot and explains it on hover. `disabled` exists so a screen can\n * keep the wrapper in place while turning the hint off, rather than restructuring the element tree to\n * remove it - the tree is authored, and a conditional wrapper would be a worse thing to model.\n */\nexport function SceneTooltip({ element, slots }: RegisteredComponentProps) {\n return (\n <Tooltip\n content={stringProperty(element.properties, 'content') ?? ''}\n position={unionProperty(element.properties, 'position', positions)}\n disabled={booleanProperty(element.properties, 'disabled')}\n >\n {
|
|
1
|
+
{"version":3,"file":"SceneTooltip.js","sources":["../../../common/SceneTooltip.tsx"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { Tooltip } from '@cratis/components/Common';\nimport { RegisteredComponentProps } from '@cratis/scene.react';\nimport { booleanProperty, stringProperty, unionProperty } from '../properties';\n\n/** Which side of the wrapped content the tooltip appears on. */\nconst positions = ['top', 'right', 'bottom', 'left'] as const;\n\n/**\n * The `Cratis.Components:tooltip` component - `Tooltip` from `@cratis/components/Common`.\n *\n * Wraps whatever is in its `content` slot and explains it on hover. `disabled` exists so a screen can\n * keep the wrapper in place while turning the hint off, rather than restructuring the element tree to\n * remove it - the tree is authored, and a conditional wrapper would be a worse thing to model.\n */\nexport function SceneTooltip({ element, slots }: RegisteredComponentProps) {\n return (\n <Tooltip\n content={stringProperty(element.properties, 'content') ?? ''}\n position={unionProperty(element.properties, 'position', positions)}\n disabled={booleanProperty(element.properties, 'disabled')}\n >\n {/* Components 4 takes a single focusable trigger, which it clones to attach its own\n class and part attributes, and a Scene slot is a list. The span is that one element:\n without it a slot holding anything other than exactly one node fails to type, and a\n slot is authored content we cannot assume the shape of. */}\n <span>{slots.content}</span>\n </Tooltip>\n );\n}\n"],"names":["positions","SceneTooltip","element","slots","_jsx","Tooltip","content","stringProperty","properties","position","unionProperty","disabled","booleanProperty","span"],"mappings":";;;;;;AAOA,iEACA,MAAMA,SAAAA,GAAY;AAAC,IAAA,KAAA;AAAO,IAAA,OAAA;AAAS,IAAA,QAAA;AAAU,IAAA;AAAO,CAAA;AAEpD;;;;;;AAMC,IACM,SAASC,YAAAA,CAAa,EAAEC,OAAO,EAAEC,KAAK,EAA4B,EAAA;AACrE,IAAA,qBACIC,cAAA,CAACC,cAAAA,EAAAA;AACGC,QAAAA,OAAAA,EAASC,yBAAAA,CAAeL,OAAAA,CAAQM,UAAU,EAAE,SAAA,CAAA,IAAc,EAAA;AAC1DC,QAAAA,QAAAA,EAAUC,wBAAAA,CAAcR,OAAAA,CAAQM,UAAU,EAAE,UAAA,EAAYR,SAAAA,CAAAA;QACxDW,QAAAA,EAAUC,0BAAAA,CAAgBV,OAAAA,CAAQM,UAAU,EAAE,UAAA,CAAA;AAM9C,QAAA,QAAA,gBAAAJ,cAAA,CAACS,MAAAA,EAAAA;AAAMV,YAAAA,QAAAA,EAAAA,KAAAA,CAAMG;;;AAGzB;;;;"}
|
|
@@ -91,7 +91,9 @@ var cratisComponents = require('./cratisComponents.js');
|
|
|
91
91
|
themes: [],
|
|
92
92
|
displayName: 'Cratis Components',
|
|
93
93
|
description: "Cratis' Arc-bound data, form and dialog composites, built on PrimeReact and Tailwind.",
|
|
94
|
-
module: '@cratis/scene.components'
|
|
94
|
+
module: '@cratis/scene.components',
|
|
95
|
+
license: 'MIT',
|
|
96
|
+
licenseUrl: 'https://github.com/Cratis/Scene/blob/main/LICENSE'
|
|
95
97
|
};
|
|
96
98
|
/**
|
|
97
99
|
* The `Cratis.Components` package as a loadable bundle - the manifest above, plus the React components
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cratisComponentsPackage.js","sources":["../../cratisComponentsPackage.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { PackageKind, ScenePackage } from '@cratis/scene.model';\nimport { ScenePackageBundle } from '@cratis/scene.react';\nimport { cratisComponents, cratisComponentsPackageName } from './cratisComponents';\n\n/**\n * The `Cratis.Components` package's declaration - what a profile gets when it lists this package.\n *\n * This is the concrete case the whole package-dependency mechanism exists for. `@cratis/components` is\n * not a self-contained library: every component in it is a wrapper over a PrimeReact widget, and its own\n * styling is a `--cratis-*` token layer (`@cratis/components/tokens`) plus the component stylesheets and\n * compiled Tailwind utilities in `@cratis/components/styles`. Activate it in a profile without PrimeReact\n * and nothing renders; activate it without Tailwind and everything renders unstyled. Both are stated as\n * dependencies so a package picker can say so while the profile is being configured, instead of leaving\n * it to be discovered when the page opens.\n *\n * The version ranges are the real ones the library carries. `>=11.0.0` for PrimeReact: version 3.0.0\n * declares `primereact@^11` as a peer dependency and is built against version 11's component set, so the\n * span across the major boundary that the previous `>=10.9.0` range described is over. The `--cratis-*`\n * tokens still resolve a version 10 theme variable as their last fallback, but that is an upgrade-window\n * courtesy for an application with a compiled version 10 stylesheet still on the page - not a version of\n * PrimeReact this package can be activated against. `^4.0.0` for Tailwind, because the utility sheet is\n * compiled against Tailwind 4.\n */\nexport const cratisComponentsPackageManifest: ScenePackage = {\n name: cratisComponentsPackageName,\n version: '3.0.0',\n kind: PackageKind.ComponentLibrary,\n dependencies: [\n { name: 'PrimeReact', versionRange: '>=11.0.0' },\n { name: 'Tailwind', versionRange: '^4.0.0' },\n ],\n components: [\n 'page',\n 'dataPage',\n 'formElement',\n 'dataTable',\n 'table',\n 'observableDataTable',\n 'commandForm',\n 'inputTextField',\n 'numberField',\n 'checkboxField',\n 'textAreaField',\n 'dropdownField',\n 'sliderField',\n 'calendarField',\n 'colorPickerField',\n 'multiSelectField',\n 'chipsField',\n 'radioButtonField',\n 'radioGroupField',\n 'dialog',\n 'confirmationDialog',\n 'busyIndicatorDialog',\n 'commandDialog',\n 'stepperCommandDialog',\n 'icon',\n 'tooltip',\n 'dropdown',\n 'errorBoundary',\n 'objectContentEditor',\n 'objectNavigationalBar',\n 'schemaEditor',\n 'timeMachine',\n 'filterPanel',\n 'toolbar',\n 'toolbarButton',\n 'toolbarGroup',\n 'toolbarSeparator',\n ],\n\n // A component library ships components, and nothing else. Layouts, screen templates and dialog\n // templates all belong to a Blueprint: they are decisions about what an application looks like as a\n // whole, and this package deliberately makes none of them - it provides the Arc-bound composites a\n // template is *built from*, so that a blueprint can place a `dataPage` in a slot and configure it,\n // rather than shipping one opinionated data page nobody can rearrange.\n layouts: [],\n screenTemplates: [],\n dialogTemplates: [],\n\n // No themes either, for a different reason: `@cratis/components` has no palette of its own. It reads\n // a `--cratis-*` variable layer that resolves whatever is in front of it - the `--p-*` properties a\n // PrimeReact 11 preset emits at runtime, or a Scene theme through this package's token bridge.\n // Shipping a theme here would be this library asserting a look it was specifically built not to have.\n themes: [],\n\n displayName: 'Cratis Components',\n description: \"Cratis' Arc-bound data, form and dialog composites, built on PrimeReact and Tailwind.\",\n module: '@cratis/scene.components',\n};\n\n/**\n * The `Cratis.Components` package as a loadable bundle - the manifest above, plus the React components\n * behind the names it declares.\n *\n * No `layouts`, `screenTemplates`, `dialogTemplates` or `themes` are provided, matching a manifest that\n * declares none of them; `validatePackageBundle` is what proves the two halves agree.\n */\nexport const cratisComponentsPackage: ScenePackageBundle = {\n manifest: cratisComponentsPackageManifest,\n components: cratisComponents,\n};\n"],"names":["cratisComponentsPackageManifest","name","cratisComponentsPackageName","version","kind","PackageKind","ComponentLibrary","dependencies","versionRange","components","layouts","screenTemplates","dialogTemplates","themes","displayName","description","module","cratisComponentsPackage","manifest","cratisComponents"],"mappings":";;;;;AAAA;AACA;AAMA;;;;;;;;;;;;;;;;;;UAmBaA,+BAAAA,GAAgD;IACzDC,IAAAA,EAAMC,4CAAAA;IACNC,OAAAA,EAAS,OAAA;AACTC,IAAAA,IAAAA,EAAMC,wBAAYC,gBAAgB;IAClCC,YAAAA,EAAc;AACV,QAAA;YAAEN,IAAAA,EAAM,YAAA;YAAcO,YAAAA,EAAc;AAAW,SAAA;AAC/C,QAAA;YAAEP,IAAAA,EAAM,UAAA;YAAYO,YAAAA,EAAc;AAAS;AAC9C,KAAA;IACDC,UAAAA,EAAY;AACR,QAAA,MAAA;AACA,QAAA,UAAA;AACA,QAAA,aAAA;AACA,QAAA,WAAA;AACA,QAAA,OAAA;AACA,QAAA,qBAAA;AACA,QAAA,aAAA;AACA,QAAA,gBAAA;AACA,QAAA,aAAA;AACA,QAAA,eAAA;AACA,QAAA,eAAA;AACA,QAAA,eAAA;AACA,QAAA,aAAA;AACA,QAAA,eAAA;AACA,QAAA,kBAAA;AACA,QAAA,kBAAA;AACA,QAAA,YAAA;AACA,QAAA,kBAAA;AACA,QAAA,iBAAA;AACA,QAAA,QAAA;AACA,QAAA,oBAAA;AACA,QAAA,qBAAA;AACA,QAAA,eAAA;AACA,QAAA,sBAAA;AACA,QAAA,MAAA;AACA,QAAA,SAAA;AACA,QAAA,UAAA;AACA,QAAA,eAAA;AACA,QAAA,qBAAA;AACA,QAAA,uBAAA;AACA,QAAA,cAAA;AACA,QAAA,aAAA;AACA,QAAA,aAAA;AACA,QAAA,SAAA;AACA,QAAA,eAAA;AACA,QAAA,cAAA;AACA,QAAA;AACH,KAAA;;;;;;AAODC,IAAAA,OAAAA,EAAS,EAAE;AACXC,IAAAA,eAAAA,EAAiB,EAAE;AACnBC,IAAAA,eAAAA,EAAiB,EAAE;;;;;AAMnBC,IAAAA,MAAAA,EAAQ,EAAE;IAEVC,WAAAA,EAAa,mBAAA;IACbC,WAAAA,EAAa,uFAAA;IACbC,MAAAA,EAAQ;
|
|
1
|
+
{"version":3,"file":"cratisComponentsPackage.js","sources":["../../cratisComponentsPackage.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { PackageKind, ScenePackage } from '@cratis/scene.model';\nimport { ScenePackageBundle } from '@cratis/scene.react';\nimport { cratisComponents, cratisComponentsPackageName } from './cratisComponents';\n\n/**\n * The `Cratis.Components` package's declaration - what a profile gets when it lists this package.\n *\n * This is the concrete case the whole package-dependency mechanism exists for. `@cratis/components` is\n * not a self-contained library: every component in it is a wrapper over a PrimeReact widget, and its own\n * styling is a `--cratis-*` token layer (`@cratis/components/tokens`) plus the component stylesheets and\n * compiled Tailwind utilities in `@cratis/components/styles`. Activate it in a profile without PrimeReact\n * and nothing renders; activate it without Tailwind and everything renders unstyled. Both are stated as\n * dependencies so a package picker can say so while the profile is being configured, instead of leaving\n * it to be discovered when the page opens.\n *\n * The version ranges are the real ones the library carries. `>=11.0.0` for PrimeReact: version 3.0.0\n * declares `primereact@^11` as a peer dependency and is built against version 11's component set, so the\n * span across the major boundary that the previous `>=10.9.0` range described is over. The `--cratis-*`\n * tokens still resolve a version 10 theme variable as their last fallback, but that is an upgrade-window\n * courtesy for an application with a compiled version 10 stylesheet still on the page - not a version of\n * PrimeReact this package can be activated against. `^4.0.0` for Tailwind, because the utility sheet is\n * compiled against Tailwind 4.\n */\nexport const cratisComponentsPackageManifest: ScenePackage = {\n name: cratisComponentsPackageName,\n version: '3.0.0',\n kind: PackageKind.ComponentLibrary,\n dependencies: [\n { name: 'PrimeReact', versionRange: '>=11.0.0' },\n { name: 'Tailwind', versionRange: '^4.0.0' },\n ],\n components: [\n 'page',\n 'dataPage',\n 'formElement',\n 'dataTable',\n 'table',\n 'observableDataTable',\n 'commandForm',\n 'inputTextField',\n 'numberField',\n 'checkboxField',\n 'textAreaField',\n 'dropdownField',\n 'sliderField',\n 'calendarField',\n 'colorPickerField',\n 'multiSelectField',\n 'chipsField',\n 'radioButtonField',\n 'radioGroupField',\n 'dialog',\n 'confirmationDialog',\n 'busyIndicatorDialog',\n 'commandDialog',\n 'stepperCommandDialog',\n 'icon',\n 'tooltip',\n 'dropdown',\n 'errorBoundary',\n 'objectContentEditor',\n 'objectNavigationalBar',\n 'schemaEditor',\n 'timeMachine',\n 'filterPanel',\n 'toolbar',\n 'toolbarButton',\n 'toolbarGroup',\n 'toolbarSeparator',\n ],\n\n // A component library ships components, and nothing else. Layouts, screen templates and dialog\n // templates all belong to a Blueprint: they are decisions about what an application looks like as a\n // whole, and this package deliberately makes none of them - it provides the Arc-bound composites a\n // template is *built from*, so that a blueprint can place a `dataPage` in a slot and configure it,\n // rather than shipping one opinionated data page nobody can rearrange.\n layouts: [],\n screenTemplates: [],\n dialogTemplates: [],\n\n // No themes either, for a different reason: `@cratis/components` has no palette of its own. It reads\n // a `--cratis-*` variable layer that resolves whatever is in front of it - the `--p-*` properties a\n // PrimeReact 11 preset emits at runtime, or a Scene theme through this package's token bridge.\n // Shipping a theme here would be this library asserting a look it was specifically built not to have.\n themes: [],\n\n displayName: 'Cratis Components',\n description: \"Cratis' Arc-bound data, form and dialog composites, built on PrimeReact and Tailwind.\",\n module: '@cratis/scene.components',\n license: 'MIT',\n licenseUrl: 'https://github.com/Cratis/Scene/blob/main/LICENSE',\n};\n\n/**\n * The `Cratis.Components` package as a loadable bundle - the manifest above, plus the React components\n * behind the names it declares.\n *\n * No `layouts`, `screenTemplates`, `dialogTemplates` or `themes` are provided, matching a manifest that\n * declares none of them; `validatePackageBundle` is what proves the two halves agree.\n */\nexport const cratisComponentsPackage: ScenePackageBundle = {\n manifest: cratisComponentsPackageManifest,\n components: cratisComponents,\n};\n"],"names":["cratisComponentsPackageManifest","name","cratisComponentsPackageName","version","kind","PackageKind","ComponentLibrary","dependencies","versionRange","components","layouts","screenTemplates","dialogTemplates","themes","displayName","description","module","license","licenseUrl","cratisComponentsPackage","manifest","cratisComponents"],"mappings":";;;;;AAAA;AACA;AAMA;;;;;;;;;;;;;;;;;;UAmBaA,+BAAAA,GAAgD;IACzDC,IAAAA,EAAMC,4CAAAA;IACNC,OAAAA,EAAS,OAAA;AACTC,IAAAA,IAAAA,EAAMC,wBAAYC,gBAAgB;IAClCC,YAAAA,EAAc;AACV,QAAA;YAAEN,IAAAA,EAAM,YAAA;YAAcO,YAAAA,EAAc;AAAW,SAAA;AAC/C,QAAA;YAAEP,IAAAA,EAAM,UAAA;YAAYO,YAAAA,EAAc;AAAS;AAC9C,KAAA;IACDC,UAAAA,EAAY;AACR,QAAA,MAAA;AACA,QAAA,UAAA;AACA,QAAA,aAAA;AACA,QAAA,WAAA;AACA,QAAA,OAAA;AACA,QAAA,qBAAA;AACA,QAAA,aAAA;AACA,QAAA,gBAAA;AACA,QAAA,aAAA;AACA,QAAA,eAAA;AACA,QAAA,eAAA;AACA,QAAA,eAAA;AACA,QAAA,aAAA;AACA,QAAA,eAAA;AACA,QAAA,kBAAA;AACA,QAAA,kBAAA;AACA,QAAA,YAAA;AACA,QAAA,kBAAA;AACA,QAAA,iBAAA;AACA,QAAA,QAAA;AACA,QAAA,oBAAA;AACA,QAAA,qBAAA;AACA,QAAA,eAAA;AACA,QAAA,sBAAA;AACA,QAAA,MAAA;AACA,QAAA,SAAA;AACA,QAAA,UAAA;AACA,QAAA,eAAA;AACA,QAAA,qBAAA;AACA,QAAA,uBAAA;AACA,QAAA,cAAA;AACA,QAAA,aAAA;AACA,QAAA,aAAA;AACA,QAAA,SAAA;AACA,QAAA,eAAA;AACA,QAAA,cAAA;AACA,QAAA;AACH,KAAA;;;;;;AAODC,IAAAA,OAAAA,EAAS,EAAE;AACXC,IAAAA,eAAAA,EAAiB,EAAE;AACnBC,IAAAA,eAAAA,EAAiB,EAAE;;;;;AAMnBC,IAAAA,MAAAA,EAAQ,EAAE;IAEVC,WAAAA,EAAa,mBAAA;IACbC,WAAAA,EAAa,uFAAA;IACbC,MAAAA,EAAQ,0BAAA;IACRC,OAAAA,EAAS,KAAA;IACTC,UAAAA,EAAY;AAChB;AAEA;;;;;;UAOaC,uBAAAA,GAA8C;IACvDC,QAAAA,EAAUpB,+BAAAA;IACVS,UAAAA,EAAYY;AAChB;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SceneTooltip.d.ts","sourceRoot":"","sources":["../../../common/SceneTooltip.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,wBAAwB,EAAE,MAAM,qBAAqB,CAAC;AAa/D,wBAAgB,YAAY,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,wBAAwB,+
|
|
1
|
+
{"version":3,"file":"SceneTooltip.d.ts","sourceRoot":"","sources":["../../../common/SceneTooltip.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,wBAAwB,EAAE,MAAM,qBAAqB,CAAC;AAa/D,wBAAgB,YAAY,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,wBAAwB,+BAcxE"}
|
|
@@ -19,7 +19,9 @@ import { booleanProperty, unionProperty, stringProperty } from '../properties.js
|
|
|
19
19
|
content: stringProperty(element.properties, 'content') ?? '',
|
|
20
20
|
position: unionProperty(element.properties, 'position', positions),
|
|
21
21
|
disabled: booleanProperty(element.properties, 'disabled'),
|
|
22
|
-
children:
|
|
22
|
+
children: /*#__PURE__*/ jsx("span", {
|
|
23
|
+
children: slots.content
|
|
24
|
+
})
|
|
23
25
|
});
|
|
24
26
|
}
|
|
25
27
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SceneTooltip.js","sources":["../../../common/SceneTooltip.tsx"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { Tooltip } from '@cratis/components/Common';\nimport { RegisteredComponentProps } from '@cratis/scene.react';\nimport { booleanProperty, stringProperty, unionProperty } from '../properties';\n\n/** Which side of the wrapped content the tooltip appears on. */\nconst positions = ['top', 'right', 'bottom', 'left'] as const;\n\n/**\n * The `Cratis.Components:tooltip` component - `Tooltip` from `@cratis/components/Common`.\n *\n * Wraps whatever is in its `content` slot and explains it on hover. `disabled` exists so a screen can\n * keep the wrapper in place while turning the hint off, rather than restructuring the element tree to\n * remove it - the tree is authored, and a conditional wrapper would be a worse thing to model.\n */\nexport function SceneTooltip({ element, slots }: RegisteredComponentProps) {\n return (\n <Tooltip\n content={stringProperty(element.properties, 'content') ?? ''}\n position={unionProperty(element.properties, 'position', positions)}\n disabled={booleanProperty(element.properties, 'disabled')}\n >\n {
|
|
1
|
+
{"version":3,"file":"SceneTooltip.js","sources":["../../../common/SceneTooltip.tsx"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { Tooltip } from '@cratis/components/Common';\nimport { RegisteredComponentProps } from '@cratis/scene.react';\nimport { booleanProperty, stringProperty, unionProperty } from '../properties';\n\n/** Which side of the wrapped content the tooltip appears on. */\nconst positions = ['top', 'right', 'bottom', 'left'] as const;\n\n/**\n * The `Cratis.Components:tooltip` component - `Tooltip` from `@cratis/components/Common`.\n *\n * Wraps whatever is in its `content` slot and explains it on hover. `disabled` exists so a screen can\n * keep the wrapper in place while turning the hint off, rather than restructuring the element tree to\n * remove it - the tree is authored, and a conditional wrapper would be a worse thing to model.\n */\nexport function SceneTooltip({ element, slots }: RegisteredComponentProps) {\n return (\n <Tooltip\n content={stringProperty(element.properties, 'content') ?? ''}\n position={unionProperty(element.properties, 'position', positions)}\n disabled={booleanProperty(element.properties, 'disabled')}\n >\n {/* Components 4 takes a single focusable trigger, which it clones to attach its own\n class and part attributes, and a Scene slot is a list. The span is that one element:\n without it a slot holding anything other than exactly one node fails to type, and a\n slot is authored content we cannot assume the shape of. */}\n <span>{slots.content}</span>\n </Tooltip>\n );\n}\n"],"names":["positions","SceneTooltip","element","slots","_jsx","Tooltip","content","stringProperty","properties","position","unionProperty","disabled","booleanProperty","span"],"mappings":";;;;AAOA,iEACA,MAAMA,SAAAA,GAAY;AAAC,IAAA,KAAA;AAAO,IAAA,OAAA;AAAS,IAAA,QAAA;AAAU,IAAA;AAAO,CAAA;AAEpD;;;;;;AAMC,IACM,SAASC,YAAAA,CAAa,EAAEC,OAAO,EAAEC,KAAK,EAA4B,EAAA;AACrE,IAAA,qBACIC,GAAA,CAACC,OAAAA,EAAAA;AACGC,QAAAA,OAAAA,EAASC,cAAAA,CAAeL,OAAAA,CAAQM,UAAU,EAAE,SAAA,CAAA,IAAc,EAAA;AAC1DC,QAAAA,QAAAA,EAAUC,aAAAA,CAAcR,OAAAA,CAAQM,UAAU,EAAE,UAAA,EAAYR,SAAAA,CAAAA;QACxDW,QAAAA,EAAUC,eAAAA,CAAgBV,OAAAA,CAAQM,UAAU,EAAE,UAAA,CAAA;AAM9C,QAAA,QAAA,gBAAAJ,GAAA,CAACS,MAAAA,EAAAA;AAAMV,YAAAA,QAAAA,EAAAA,KAAAA,CAAMG;;;AAGzB;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cratisComponentsPackage.d.ts","sourceRoot":"","sources":["../../cratisComponentsPackage.ts"],"names":[],"mappings":"AAGA,OAAO,EAAe,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AAsBzD,eAAO,MAAM,+BAA+B,EAAE,
|
|
1
|
+
{"version":3,"file":"cratisComponentsPackage.d.ts","sourceRoot":"","sources":["../../cratisComponentsPackage.ts"],"names":[],"mappings":"AAGA,OAAO,EAAe,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AAsBzD,eAAO,MAAM,+BAA+B,EAAE,YAoE7C,CAAC;AASF,eAAO,MAAM,uBAAuB,EAAE,kBAGrC,CAAC"}
|
|
@@ -89,7 +89,9 @@ import { cratisComponents, cratisComponentsPackageName } from './cratisComponent
|
|
|
89
89
|
themes: [],
|
|
90
90
|
displayName: 'Cratis Components',
|
|
91
91
|
description: "Cratis' Arc-bound data, form and dialog composites, built on PrimeReact and Tailwind.",
|
|
92
|
-
module: '@cratis/scene.components'
|
|
92
|
+
module: '@cratis/scene.components',
|
|
93
|
+
license: 'MIT',
|
|
94
|
+
licenseUrl: 'https://github.com/Cratis/Scene/blob/main/LICENSE'
|
|
93
95
|
};
|
|
94
96
|
/**
|
|
95
97
|
* The `Cratis.Components` package as a loadable bundle - the manifest above, plus the React components
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cratisComponentsPackage.js","sources":["../../cratisComponentsPackage.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { PackageKind, ScenePackage } from '@cratis/scene.model';\nimport { ScenePackageBundle } from '@cratis/scene.react';\nimport { cratisComponents, cratisComponentsPackageName } from './cratisComponents';\n\n/**\n * The `Cratis.Components` package's declaration - what a profile gets when it lists this package.\n *\n * This is the concrete case the whole package-dependency mechanism exists for. `@cratis/components` is\n * not a self-contained library: every component in it is a wrapper over a PrimeReact widget, and its own\n * styling is a `--cratis-*` token layer (`@cratis/components/tokens`) plus the component stylesheets and\n * compiled Tailwind utilities in `@cratis/components/styles`. Activate it in a profile without PrimeReact\n * and nothing renders; activate it without Tailwind and everything renders unstyled. Both are stated as\n * dependencies so a package picker can say so while the profile is being configured, instead of leaving\n * it to be discovered when the page opens.\n *\n * The version ranges are the real ones the library carries. `>=11.0.0` for PrimeReact: version 3.0.0\n * declares `primereact@^11` as a peer dependency and is built against version 11's component set, so the\n * span across the major boundary that the previous `>=10.9.0` range described is over. The `--cratis-*`\n * tokens still resolve a version 10 theme variable as their last fallback, but that is an upgrade-window\n * courtesy for an application with a compiled version 10 stylesheet still on the page - not a version of\n * PrimeReact this package can be activated against. `^4.0.0` for Tailwind, because the utility sheet is\n * compiled against Tailwind 4.\n */\nexport const cratisComponentsPackageManifest: ScenePackage = {\n name: cratisComponentsPackageName,\n version: '3.0.0',\n kind: PackageKind.ComponentLibrary,\n dependencies: [\n { name: 'PrimeReact', versionRange: '>=11.0.0' },\n { name: 'Tailwind', versionRange: '^4.0.0' },\n ],\n components: [\n 'page',\n 'dataPage',\n 'formElement',\n 'dataTable',\n 'table',\n 'observableDataTable',\n 'commandForm',\n 'inputTextField',\n 'numberField',\n 'checkboxField',\n 'textAreaField',\n 'dropdownField',\n 'sliderField',\n 'calendarField',\n 'colorPickerField',\n 'multiSelectField',\n 'chipsField',\n 'radioButtonField',\n 'radioGroupField',\n 'dialog',\n 'confirmationDialog',\n 'busyIndicatorDialog',\n 'commandDialog',\n 'stepperCommandDialog',\n 'icon',\n 'tooltip',\n 'dropdown',\n 'errorBoundary',\n 'objectContentEditor',\n 'objectNavigationalBar',\n 'schemaEditor',\n 'timeMachine',\n 'filterPanel',\n 'toolbar',\n 'toolbarButton',\n 'toolbarGroup',\n 'toolbarSeparator',\n ],\n\n // A component library ships components, and nothing else. Layouts, screen templates and dialog\n // templates all belong to a Blueprint: they are decisions about what an application looks like as a\n // whole, and this package deliberately makes none of them - it provides the Arc-bound composites a\n // template is *built from*, so that a blueprint can place a `dataPage` in a slot and configure it,\n // rather than shipping one opinionated data page nobody can rearrange.\n layouts: [],\n screenTemplates: [],\n dialogTemplates: [],\n\n // No themes either, for a different reason: `@cratis/components` has no palette of its own. It reads\n // a `--cratis-*` variable layer that resolves whatever is in front of it - the `--p-*` properties a\n // PrimeReact 11 preset emits at runtime, or a Scene theme through this package's token bridge.\n // Shipping a theme here would be this library asserting a look it was specifically built not to have.\n themes: [],\n\n displayName: 'Cratis Components',\n description: \"Cratis' Arc-bound data, form and dialog composites, built on PrimeReact and Tailwind.\",\n module: '@cratis/scene.components',\n};\n\n/**\n * The `Cratis.Components` package as a loadable bundle - the manifest above, plus the React components\n * behind the names it declares.\n *\n * No `layouts`, `screenTemplates`, `dialogTemplates` or `themes` are provided, matching a manifest that\n * declares none of them; `validatePackageBundle` is what proves the two halves agree.\n */\nexport const cratisComponentsPackage: ScenePackageBundle = {\n manifest: cratisComponentsPackageManifest,\n components: cratisComponents,\n};\n"],"names":["cratisComponentsPackageManifest","name","cratisComponentsPackageName","version","kind","PackageKind","ComponentLibrary","dependencies","versionRange","components","layouts","screenTemplates","dialogTemplates","themes","displayName","description","module","cratisComponentsPackage","manifest","cratisComponents"],"mappings":";;;AAAA;AACA;AAMA;;;;;;;;;;;;;;;;;;UAmBaA,+BAAAA,GAAgD;IACzDC,IAAAA,EAAMC,2BAAAA;IACNC,OAAAA,EAAS,OAAA;AACTC,IAAAA,IAAAA,EAAMC,YAAYC,gBAAgB;IAClCC,YAAAA,EAAc;AACV,QAAA;YAAEN,IAAAA,EAAM,YAAA;YAAcO,YAAAA,EAAc;AAAW,SAAA;AAC/C,QAAA;YAAEP,IAAAA,EAAM,UAAA;YAAYO,YAAAA,EAAc;AAAS;AAC9C,KAAA;IACDC,UAAAA,EAAY;AACR,QAAA,MAAA;AACA,QAAA,UAAA;AACA,QAAA,aAAA;AACA,QAAA,WAAA;AACA,QAAA,OAAA;AACA,QAAA,qBAAA;AACA,QAAA,aAAA;AACA,QAAA,gBAAA;AACA,QAAA,aAAA;AACA,QAAA,eAAA;AACA,QAAA,eAAA;AACA,QAAA,eAAA;AACA,QAAA,aAAA;AACA,QAAA,eAAA;AACA,QAAA,kBAAA;AACA,QAAA,kBAAA;AACA,QAAA,YAAA;AACA,QAAA,kBAAA;AACA,QAAA,iBAAA;AACA,QAAA,QAAA;AACA,QAAA,oBAAA;AACA,QAAA,qBAAA;AACA,QAAA,eAAA;AACA,QAAA,sBAAA;AACA,QAAA,MAAA;AACA,QAAA,SAAA;AACA,QAAA,UAAA;AACA,QAAA,eAAA;AACA,QAAA,qBAAA;AACA,QAAA,uBAAA;AACA,QAAA,cAAA;AACA,QAAA,aAAA;AACA,QAAA,aAAA;AACA,QAAA,SAAA;AACA,QAAA,eAAA;AACA,QAAA,cAAA;AACA,QAAA;AACH,KAAA;;;;;;AAODC,IAAAA,OAAAA,EAAS,EAAE;AACXC,IAAAA,eAAAA,EAAiB,EAAE;AACnBC,IAAAA,eAAAA,EAAiB,EAAE;;;;;AAMnBC,IAAAA,MAAAA,EAAQ,EAAE;IAEVC,WAAAA,EAAa,mBAAA;IACbC,WAAAA,EAAa,uFAAA;IACbC,MAAAA,EAAQ;
|
|
1
|
+
{"version":3,"file":"cratisComponentsPackage.js","sources":["../../cratisComponentsPackage.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { PackageKind, ScenePackage } from '@cratis/scene.model';\nimport { ScenePackageBundle } from '@cratis/scene.react';\nimport { cratisComponents, cratisComponentsPackageName } from './cratisComponents';\n\n/**\n * The `Cratis.Components` package's declaration - what a profile gets when it lists this package.\n *\n * This is the concrete case the whole package-dependency mechanism exists for. `@cratis/components` is\n * not a self-contained library: every component in it is a wrapper over a PrimeReact widget, and its own\n * styling is a `--cratis-*` token layer (`@cratis/components/tokens`) plus the component stylesheets and\n * compiled Tailwind utilities in `@cratis/components/styles`. Activate it in a profile without PrimeReact\n * and nothing renders; activate it without Tailwind and everything renders unstyled. Both are stated as\n * dependencies so a package picker can say so while the profile is being configured, instead of leaving\n * it to be discovered when the page opens.\n *\n * The version ranges are the real ones the library carries. `>=11.0.0` for PrimeReact: version 3.0.0\n * declares `primereact@^11` as a peer dependency and is built against version 11's component set, so the\n * span across the major boundary that the previous `>=10.9.0` range described is over. The `--cratis-*`\n * tokens still resolve a version 10 theme variable as their last fallback, but that is an upgrade-window\n * courtesy for an application with a compiled version 10 stylesheet still on the page - not a version of\n * PrimeReact this package can be activated against. `^4.0.0` for Tailwind, because the utility sheet is\n * compiled against Tailwind 4.\n */\nexport const cratisComponentsPackageManifest: ScenePackage = {\n name: cratisComponentsPackageName,\n version: '3.0.0',\n kind: PackageKind.ComponentLibrary,\n dependencies: [\n { name: 'PrimeReact', versionRange: '>=11.0.0' },\n { name: 'Tailwind', versionRange: '^4.0.0' },\n ],\n components: [\n 'page',\n 'dataPage',\n 'formElement',\n 'dataTable',\n 'table',\n 'observableDataTable',\n 'commandForm',\n 'inputTextField',\n 'numberField',\n 'checkboxField',\n 'textAreaField',\n 'dropdownField',\n 'sliderField',\n 'calendarField',\n 'colorPickerField',\n 'multiSelectField',\n 'chipsField',\n 'radioButtonField',\n 'radioGroupField',\n 'dialog',\n 'confirmationDialog',\n 'busyIndicatorDialog',\n 'commandDialog',\n 'stepperCommandDialog',\n 'icon',\n 'tooltip',\n 'dropdown',\n 'errorBoundary',\n 'objectContentEditor',\n 'objectNavigationalBar',\n 'schemaEditor',\n 'timeMachine',\n 'filterPanel',\n 'toolbar',\n 'toolbarButton',\n 'toolbarGroup',\n 'toolbarSeparator',\n ],\n\n // A component library ships components, and nothing else. Layouts, screen templates and dialog\n // templates all belong to a Blueprint: they are decisions about what an application looks like as a\n // whole, and this package deliberately makes none of them - it provides the Arc-bound composites a\n // template is *built from*, so that a blueprint can place a `dataPage` in a slot and configure it,\n // rather than shipping one opinionated data page nobody can rearrange.\n layouts: [],\n screenTemplates: [],\n dialogTemplates: [],\n\n // No themes either, for a different reason: `@cratis/components` has no palette of its own. It reads\n // a `--cratis-*` variable layer that resolves whatever is in front of it - the `--p-*` properties a\n // PrimeReact 11 preset emits at runtime, or a Scene theme through this package's token bridge.\n // Shipping a theme here would be this library asserting a look it was specifically built not to have.\n themes: [],\n\n displayName: 'Cratis Components',\n description: \"Cratis' Arc-bound data, form and dialog composites, built on PrimeReact and Tailwind.\",\n module: '@cratis/scene.components',\n license: 'MIT',\n licenseUrl: 'https://github.com/Cratis/Scene/blob/main/LICENSE',\n};\n\n/**\n * The `Cratis.Components` package as a loadable bundle - the manifest above, plus the React components\n * behind the names it declares.\n *\n * No `layouts`, `screenTemplates`, `dialogTemplates` or `themes` are provided, matching a manifest that\n * declares none of them; `validatePackageBundle` is what proves the two halves agree.\n */\nexport const cratisComponentsPackage: ScenePackageBundle = {\n manifest: cratisComponentsPackageManifest,\n components: cratisComponents,\n};\n"],"names":["cratisComponentsPackageManifest","name","cratisComponentsPackageName","version","kind","PackageKind","ComponentLibrary","dependencies","versionRange","components","layouts","screenTemplates","dialogTemplates","themes","displayName","description","module","license","licenseUrl","cratisComponentsPackage","manifest","cratisComponents"],"mappings":";;;AAAA;AACA;AAMA;;;;;;;;;;;;;;;;;;UAmBaA,+BAAAA,GAAgD;IACzDC,IAAAA,EAAMC,2BAAAA;IACNC,OAAAA,EAAS,OAAA;AACTC,IAAAA,IAAAA,EAAMC,YAAYC,gBAAgB;IAClCC,YAAAA,EAAc;AACV,QAAA;YAAEN,IAAAA,EAAM,YAAA;YAAcO,YAAAA,EAAc;AAAW,SAAA;AAC/C,QAAA;YAAEP,IAAAA,EAAM,UAAA;YAAYO,YAAAA,EAAc;AAAS;AAC9C,KAAA;IACDC,UAAAA,EAAY;AACR,QAAA,MAAA;AACA,QAAA,UAAA;AACA,QAAA,aAAA;AACA,QAAA,WAAA;AACA,QAAA,OAAA;AACA,QAAA,qBAAA;AACA,QAAA,aAAA;AACA,QAAA,gBAAA;AACA,QAAA,aAAA;AACA,QAAA,eAAA;AACA,QAAA,eAAA;AACA,QAAA,eAAA;AACA,QAAA,aAAA;AACA,QAAA,eAAA;AACA,QAAA,kBAAA;AACA,QAAA,kBAAA;AACA,QAAA,YAAA;AACA,QAAA,kBAAA;AACA,QAAA,iBAAA;AACA,QAAA,QAAA;AACA,QAAA,oBAAA;AACA,QAAA,qBAAA;AACA,QAAA,eAAA;AACA,QAAA,sBAAA;AACA,QAAA,MAAA;AACA,QAAA,SAAA;AACA,QAAA,UAAA;AACA,QAAA,eAAA;AACA,QAAA,qBAAA;AACA,QAAA,uBAAA;AACA,QAAA,cAAA;AACA,QAAA,aAAA;AACA,QAAA,aAAA;AACA,QAAA,SAAA;AACA,QAAA,eAAA;AACA,QAAA,cAAA;AACA,QAAA;AACH,KAAA;;;;;;AAODC,IAAAA,OAAAA,EAAS,EAAE;AACXC,IAAAA,eAAAA,EAAiB,EAAE;AACnBC,IAAAA,eAAAA,EAAiB,EAAE;;;;;AAMnBC,IAAAA,MAAAA,EAAQ,EAAE;IAEVC,WAAAA,EAAa,mBAAA;IACbC,WAAAA,EAAa,uFAAA;IACbC,MAAAA,EAAQ,0BAAA;IACRC,OAAAA,EAAS,KAAA;IACTC,UAAAA,EAAY;AAChB;AAEA;;;;;;UAOaC,uBAAAA,GAA8C;IACvDC,QAAAA,EAAUpB,+BAAAA;IACVS,UAAAA,EAAYY;AAChB;;;;"}
|
package/dist/esm/editors/for_SceneObjectNavigationalBar/when_navigating_back_up_the_trail.js
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { fireEvent, render, screen } from '@testing-library/react';
|
|
3
|
-
import { PrimeReactProvider } from '@primereact/core';
|
|
4
3
|
import { externalComponent } from '../../given';
|
|
5
4
|
import { SceneObjectNavigationalBar } from '../SceneObjectNavigationalBar';
|
|
6
5
|
describe('when navigating back up the trail', () => {
|
|
7
6
|
beforeEach(() => {
|
|
8
7
|
const element = externalComponent('Cratis.Components:objectNavigationalBar', { navigationPath: ['shipping', 'address', 'street'] });
|
|
9
|
-
render(_jsx(
|
|
8
|
+
render(_jsx(SceneObjectNavigationalBar, { element: element, slots: {} }));
|
|
10
9
|
fireEvent.click(screen.getByText('address'));
|
|
11
10
|
});
|
|
12
11
|
it('should keep the crumb that was clicked', () => screen.getByText('address').textContent.should.equal('address'));
|
package/dist/esm/editors/for_SceneObjectNavigationalBar/when_navigating_back_up_the_trail.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"when_navigating_back_up_the_trail.js","sourceRoot":"","sources":["../../../../editors/for_SceneObjectNavigationalBar/when_navigating_back_up_the_trail.tsx"],"names":[],"mappings":";AAGA,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AACnE,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"when_navigating_back_up_the_trail.js","sourceRoot":"","sources":["../../../../editors/for_SceneObjectNavigationalBar/when_navigating_back_up_the_trail.tsx"],"names":[],"mappings":";AAGA,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AACnE,OAAO,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,EAAE,0BAA0B,EAAE,MAAM,+BAA+B,CAAC;AAE3E,QAAQ,CAAC,mCAAmC,EAAE,GAAG,EAAE;IAO/C,UAAU,CAAC,GAAG,EAAE;QACZ,MAAM,OAAO,GAAG,iBAAiB,CAAC,yCAAyC,EAAE,EAAE,cAAc,EAAE,CAAC,UAAU,EAAE,SAAS,EAAE,QAAQ,CAAC,EAAE,CAAC,CAAC;QACpI,MAAM,CAAC,KAAC,0BAA0B,IAAC,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,GAAI,CAAC,CAAC;QACpE,SAAS,CAAC,KAAK,CAAC,MAAM,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,CAAC;IACjD,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,wCAAwC,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,WAAY,CAAC,MAAM,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC;IACrH,EAAE,CAAC,iCAAiC,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC,WAAY,CAAC,MAAM,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC;IAChH,EAAE,CAAC,iCAAiC,EAAE,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,WAAW,CAAC,QAAQ,CAAC,KAAK,IAAI,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC;AACxG,CAAC,CAAC,CAAC"}
|