@cratis/scene.primereact 4.15.0 → 4.17.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/dist/cjs/form/PrimeCalendar.js +3 -1
- package/dist/cjs/form/PrimeCalendar.js.map +1 -1
- package/dist/cjs/form/PrimeCheckbox.js +4 -2
- package/dist/cjs/form/PrimeCheckbox.js.map +1 -1
- package/dist/cjs/form/PrimeDropdown.js +3 -1
- package/dist/cjs/form/PrimeDropdown.js.map +1 -1
- package/dist/cjs/form/PrimeInputNumber.js +3 -1
- package/dist/cjs/form/PrimeInputNumber.js.map +1 -1
- package/dist/cjs/form/PrimeInputText.js +3 -1
- package/dist/cjs/form/PrimeInputText.js.map +1 -1
- package/dist/cjs/form/PrimeInputTextarea.js +3 -1
- package/dist/cjs/form/PrimeInputTextarea.js.map +1 -1
- package/dist/cjs/form/PrimeMultiSelect.js +3 -1
- package/dist/cjs/form/PrimeMultiSelect.js.map +1 -1
- package/dist/cjs/form/PrimePassword.js +3 -1
- package/dist/cjs/form/PrimePassword.js.map +1 -1
- package/dist/cjs/form/PrimeRadioButton.js +3 -1
- package/dist/cjs/form/PrimeRadioButton.js.map +1 -1
- package/dist/cjs/form/PrimeToggleSwitch.js +4 -1
- package/dist/cjs/form/PrimeToggleSwitch.js.map +1 -1
- package/dist/cjs/inputDescriptors.js +86 -0
- package/dist/cjs/inputDescriptors.js.map +1 -0
- package/dist/cjs/primeReactDescriptors.js +2 -0
- package/dist/cjs/primeReactDescriptors.js.map +1 -1
- package/dist/esm/form/PrimeCalendar.d.ts +1 -1
- package/dist/esm/form/PrimeCalendar.d.ts.map +1 -1
- package/dist/esm/form/PrimeCalendar.js +3 -1
- package/dist/esm/form/PrimeCalendar.js.map +1 -1
- package/dist/esm/form/PrimeCheckbox.d.ts +1 -1
- package/dist/esm/form/PrimeCheckbox.d.ts.map +1 -1
- package/dist/esm/form/PrimeCheckbox.js +4 -2
- package/dist/esm/form/PrimeCheckbox.js.map +1 -1
- package/dist/esm/form/PrimeDropdown.d.ts +1 -1
- package/dist/esm/form/PrimeDropdown.d.ts.map +1 -1
- package/dist/esm/form/PrimeDropdown.js +3 -1
- package/dist/esm/form/PrimeDropdown.js.map +1 -1
- package/dist/esm/form/PrimeInputNumber.d.ts +1 -1
- package/dist/esm/form/PrimeInputNumber.d.ts.map +1 -1
- package/dist/esm/form/PrimeInputNumber.js +3 -1
- package/dist/esm/form/PrimeInputNumber.js.map +1 -1
- package/dist/esm/form/PrimeInputText.d.ts +1 -1
- package/dist/esm/form/PrimeInputText.d.ts.map +1 -1
- package/dist/esm/form/PrimeInputText.js +3 -1
- package/dist/esm/form/PrimeInputText.js.map +1 -1
- package/dist/esm/form/PrimeInputTextarea.d.ts +1 -1
- package/dist/esm/form/PrimeInputTextarea.d.ts.map +1 -1
- package/dist/esm/form/PrimeInputTextarea.js +3 -1
- package/dist/esm/form/PrimeInputTextarea.js.map +1 -1
- package/dist/esm/form/PrimeMultiSelect.d.ts +1 -1
- package/dist/esm/form/PrimeMultiSelect.d.ts.map +1 -1
- package/dist/esm/form/PrimeMultiSelect.js +3 -1
- package/dist/esm/form/PrimeMultiSelect.js.map +1 -1
- package/dist/esm/form/PrimePassword.d.ts +1 -1
- package/dist/esm/form/PrimePassword.d.ts.map +1 -1
- package/dist/esm/form/PrimePassword.js +3 -1
- package/dist/esm/form/PrimePassword.js.map +1 -1
- package/dist/esm/form/PrimeRadioButton.d.ts +1 -1
- package/dist/esm/form/PrimeRadioButton.d.ts.map +1 -1
- package/dist/esm/form/PrimeRadioButton.js +3 -1
- package/dist/esm/form/PrimeRadioButton.js.map +1 -1
- package/dist/esm/form/PrimeToggleSwitch.d.ts +1 -1
- package/dist/esm/form/PrimeToggleSwitch.d.ts.map +1 -1
- package/dist/esm/form/PrimeToggleSwitch.js +4 -1
- package/dist/esm/form/PrimeToggleSwitch.js.map +1 -1
- package/dist/esm/inputDescriptors.d.ts +3 -0
- package/dist/esm/inputDescriptors.d.ts.map +1 -0
- package/dist/esm/inputDescriptors.js +84 -0
- package/dist/esm/inputDescriptors.js.map +1 -0
- package/dist/esm/primeReactDescriptors.d.ts.map +1 -1
- package/dist/esm/primeReactDescriptors.js +2 -0
- package/dist/esm/primeReactDescriptors.js.map +1 -1
- package/dist/esm/tsconfig.tsbuildinfo +1 -1
- package/form/PrimeCalendar.tsx +3 -2
- package/form/PrimeCheckbox.tsx +4 -3
- package/form/PrimeDropdown.tsx +3 -2
- package/form/PrimeInputNumber.tsx +3 -2
- package/form/PrimeInputText.tsx +3 -2
- package/form/PrimeInputTextarea.tsx +3 -2
- package/form/PrimeMultiSelect.tsx +3 -2
- package/form/PrimePassword.tsx +3 -2
- package/form/PrimeRadioButton.tsx +3 -2
- package/form/PrimeToggleSwitch.tsx +4 -2
- package/inputDescriptors.ts +38 -0
- package/package.json +7 -7
- package/primeReactDescriptors.ts +2 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import { useState } from 'react';
|
|
3
3
|
import { RadioButton } from 'primereact/radiobutton';
|
|
4
|
+
import { useValueOutput } from '@cratis/scene.react';
|
|
4
5
|
import { stringProperty, optionsProperty, booleanProperty } from '../properties.js';
|
|
5
6
|
|
|
6
7
|
/**
|
|
@@ -15,8 +16,9 @@ import { stringProperty, optionsProperty, booleanProperty } from '../properties.
|
|
|
15
16
|
* `Indicator`, and reports selection as `onCheckedChange`. Only the transition *into* checked is acted
|
|
16
17
|
* on: the browser also fires the sibling losing its check, and treating that as a selection would clear
|
|
17
18
|
* the value a moment after the user set it.
|
|
18
|
-
*/ function PrimeRadioButton({ element }) {
|
|
19
|
+
*/ function PrimeRadioButton({ element, bindingOutputs }) {
|
|
19
20
|
const [value, setValue] = useState(stringProperty(element, 'value'));
|
|
21
|
+
useValueOutput(bindingOutputs, value);
|
|
20
22
|
const options = optionsProperty(element, 'options');
|
|
21
23
|
const choices = options.length > 0 ? options : [
|
|
22
24
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrimeRadioButton.js","sources":["../../../form/PrimeRadioButton.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 { useState } from 'react';\nimport { RadioButton } from 'primereact/radiobutton';\nimport { RegisteredComponentProps } from '@cratis/scene.react';\nimport { booleanProperty, optionsProperty, stringProperty } from '../properties';\n\n/**\n * The `PrimeReact:radioButton` component - one exclusive choice out of several.\n *\n * PrimeReact's RadioButton is a single button, but a lone radio button is never what a screen means: the\n * choice is the group. The adapter therefore renders the whole group from `options`, sharing one\n * `name` so the browser enforces exclusivity, and falls back to a single button when only a `label` was\n * given.\n *\n * PrimeReact 11 splits each button into `Root` (the real radio input and its state), `Box` and\n * `Indicator`, and reports selection as `onCheckedChange`. Only the transition *into* checked is acted\n * on: the browser also fires the sibling losing its check, and treating that as a selection would clear\n * the value a moment after the user set it.\n */\nexport function PrimeRadioButton({ element }: RegisteredComponentProps) {\n const [value, setValue] = useState<string | undefined>(stringProperty(element, 'value'));\n const options = optionsProperty(element, 'options');\n const choices = options.length > 0 ? options : [{ label: stringProperty(element, 'label', 'Option'), value: element.id }];\n const disabled = booleanProperty(element, 'disabled', false);\n return (\n <div data-scene-id={element.id} className='flex flex-col gap-2'>\n {choices.map((choice) => (\n <div key={choice.value} className='flex items-center gap-2'>\n <RadioButton.Root\n inputId={`${element.id}-${choice.value}`}\n name={element.id}\n value={choice.value}\n checked={value === choice.value}\n onCheckedChange={(event) => {\n if (event.checked) setValue(choice.value);\n }}\n disabled={disabled}>\n <RadioButton.Box>\n <RadioButton.Indicator />\n </RadioButton.Box>\n </RadioButton.Root>\n <label htmlFor={`${element.id}-${choice.value}`}>{choice.label}</label>\n </div>\n ))}\n </div>\n );\n}\n"],"names":["PrimeRadioButton","element","value","setValue","useState","stringProperty","options","optionsProperty","choices","length","label","id","disabled","booleanProperty","_jsx","div","data-scene-id","className","map","choice","_jsxs","RadioButton","Root","inputId","name","checked","onCheckedChange","event","Box","Indicator","htmlFor"],"mappings":"
|
|
1
|
+
{"version":3,"file":"PrimeRadioButton.js","sources":["../../../form/PrimeRadioButton.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 { useState } from 'react';\nimport { RadioButton } from 'primereact/radiobutton';\nimport { RegisteredComponentProps, useValueOutput } from '@cratis/scene.react';\nimport { booleanProperty, optionsProperty, stringProperty } from '../properties';\n\n/**\n * The `PrimeReact:radioButton` component - one exclusive choice out of several.\n *\n * PrimeReact's RadioButton is a single button, but a lone radio button is never what a screen means: the\n * choice is the group. The adapter therefore renders the whole group from `options`, sharing one\n * `name` so the browser enforces exclusivity, and falls back to a single button when only a `label` was\n * given.\n *\n * PrimeReact 11 splits each button into `Root` (the real radio input and its state), `Box` and\n * `Indicator`, and reports selection as `onCheckedChange`. Only the transition *into* checked is acted\n * on: the browser also fires the sibling losing its check, and treating that as a selection would clear\n * the value a moment after the user set it.\n */\nexport function PrimeRadioButton({ element, bindingOutputs }: RegisteredComponentProps) {\n const [value, setValue] = useState<string | undefined>(stringProperty(element, 'value'));\n useValueOutput(bindingOutputs, value);\n const options = optionsProperty(element, 'options');\n const choices = options.length > 0 ? options : [{ label: stringProperty(element, 'label', 'Option'), value: element.id }];\n const disabled = booleanProperty(element, 'disabled', false);\n return (\n <div data-scene-id={element.id} className='flex flex-col gap-2'>\n {choices.map((choice) => (\n <div key={choice.value} className='flex items-center gap-2'>\n <RadioButton.Root\n inputId={`${element.id}-${choice.value}`}\n name={element.id}\n value={choice.value}\n checked={value === choice.value}\n onCheckedChange={(event) => {\n if (event.checked) setValue(choice.value);\n }}\n disabled={disabled}>\n <RadioButton.Box>\n <RadioButton.Indicator />\n </RadioButton.Box>\n </RadioButton.Root>\n <label htmlFor={`${element.id}-${choice.value}`}>{choice.label}</label>\n </div>\n ))}\n </div>\n );\n}\n"],"names":["PrimeRadioButton","element","bindingOutputs","value","setValue","useState","stringProperty","useValueOutput","options","optionsProperty","choices","length","label","id","disabled","booleanProperty","_jsx","div","data-scene-id","className","map","choice","_jsxs","RadioButton","Root","inputId","name","checked","onCheckedChange","event","Box","Indicator","htmlFor"],"mappings":";;;;;;AAQA;;;;;;;;;;;;AAYC,IACM,SAASA,gBAAAA,CAAiB,EAAEC,OAAO,EAAEC,cAAc,EAA4B,EAAA;AAClF,IAAA,MAAM,CAACC,KAAAA,EAAOC,QAAAA,CAAS,GAAGC,QAAAA,CAA6BC,eAAeL,OAAAA,EAAS,OAAA,CAAA,CAAA;AAC/EM,IAAAA,cAAAA,CAAeL,cAAAA,EAAgBC,KAAAA,CAAAA;IAC/B,MAAMK,OAAAA,GAAUC,gBAAgBR,OAAAA,EAAS,SAAA,CAAA;AACzC,IAAA,MAAMS,OAAAA,GAAUF,OAAAA,CAAQG,MAAM,GAAG,IAAIH,OAAAA,GAAU;AAAC,QAAA;YAAEI,KAAAA,EAAON,cAAAA,CAAeL,SAAS,OAAA,EAAS,QAAA,CAAA;AAAWE,YAAAA,KAAAA,EAAOF,QAAQY;AAAG;AAAE,KAAA;IACzH,MAAMC,QAAAA,GAAWC,eAAAA,CAAgBd,OAAAA,EAAS,UAAA,EAAY,KAAA,CAAA;AACtD,IAAA,qBACIe,GAAA,CAACC,KAAAA,EAAAA;AAAIC,QAAAA,eAAAA,EAAejB,QAAQY,EAAE;QAAEM,SAAAA,EAAU,qBAAA;AACrCT,QAAAA,QAAAA,EAAAA,OAAAA,CAAQU,GAAG,CAAC,CAACC,MAAAA,iBACVC,IAAA,CAACL,KAAAA,EAAAA;gBAAuBE,SAAAA,EAAU,yBAAA;;AAC9B,kCAAAH,GAAA,CAACO,YAAYC,IAAI,EAAA;wBACbC,OAAAA,EAAS,CAAA,EAAGxB,QAAQY,EAAE,CAAC,CAAC,EAAEQ,MAAAA,CAAOlB,KAAK,CAAA,CAAE;AACxCuB,wBAAAA,IAAAA,EAAMzB,QAAQY,EAAE;AAChBV,wBAAAA,KAAAA,EAAOkB,OAAOlB,KAAK;wBACnBwB,OAAAA,EAASxB,KAAAA,KAAUkB,OAAOlB,KAAK;AAC/ByB,wBAAAA,eAAAA,EAAiB,CAACC,KAAAA,GAAAA;AACd,4BAAA,IAAIA,KAAAA,CAAMF,OAAO,EAAEvB,QAAAA,CAASiB,OAAOlB,KAAK,CAAA;AAC5C,wBAAA,CAAA;wBACAW,QAAAA,EAAUA,QAAAA;gDACVE,GAAA,CAACO,YAAYO,GAAG,EAAA;oDACZd,GAAA,CAACO,YAAYQ,SAAS,EAAA,EAAA;;;kCAG9Bf,GAAA,CAACJ,OAAAA,EAAAA;wBAAMoB,OAAAA,EAAS,CAAA,EAAG/B,QAAQY,EAAE,CAAC,CAAC,EAAEQ,MAAAA,CAAOlB,KAAK,CAAA,CAAE;AAAGkB,wBAAAA,QAAAA,EAAAA,MAAAA,CAAOT;;;AAdnDS,aAAAA,EAAAA,MAAAA,CAAOlB,KAAK,CAAA;;AAmBtC;;"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { RegisteredComponentProps } from '@cratis/scene.react';
|
|
2
|
-
export declare function PrimeToggleSwitch({ element }: RegisteredComponentProps): import("react").JSX.Element;
|
|
2
|
+
export declare function PrimeToggleSwitch({ element, bindingOutputs }: RegisteredComponentProps): import("react").JSX.Element;
|
|
3
3
|
//# sourceMappingURL=PrimeToggleSwitch.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrimeToggleSwitch.d.ts","sourceRoot":"","sources":["../../../form/PrimeToggleSwitch.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,wBAAwB,
|
|
1
|
+
{"version":3,"file":"PrimeToggleSwitch.d.ts","sourceRoot":"","sources":["../../../form/PrimeToggleSwitch.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,wBAAwB,EAAkB,MAAM,qBAAqB,CAAC;AAe/E,wBAAgB,iBAAiB,CAAC,EAAE,OAAO,EAAE,cAAc,EAAE,EAAE,wBAAwB,+BAmBtF"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { useState } from 'react';
|
|
3
3
|
import { ToggleSwitch } from 'primereact/toggleswitch';
|
|
4
|
+
import { useValueOutput } from '@cratis/scene.react';
|
|
4
5
|
import { booleanProperty, stringProperty } from '../properties.js';
|
|
5
6
|
|
|
6
7
|
/**
|
|
@@ -14,8 +15,9 @@ import { booleanProperty, stringProperty } from '../properties.js';
|
|
|
14
15
|
* `Root` renders the hidden checkbox that carries the state and the accessible name, and the visible
|
|
15
16
|
* switch is `Control` plus the `Handle` that slides inside it. That is why `inputId` and not `id` is what
|
|
16
17
|
* the label points at: the label has to reach the input, not the wrapper.
|
|
17
|
-
*/ function PrimeToggleSwitch({ element }) {
|
|
18
|
+
*/ function PrimeToggleSwitch({ element, bindingOutputs }) {
|
|
18
19
|
const [checked, setChecked] = useState(booleanProperty(element, 'checked', false));
|
|
20
|
+
useValueOutput(bindingOutputs, checked);
|
|
19
21
|
const label = stringProperty(element, 'label');
|
|
20
22
|
return /*#__PURE__*/ jsxs("div", {
|
|
21
23
|
"data-scene-id": element.id,
|
|
@@ -24,6 +26,7 @@ import { booleanProperty, stringProperty } from '../properties.js';
|
|
|
24
26
|
/*#__PURE__*/ jsx(ToggleSwitch.Root, {
|
|
25
27
|
inputId: element.id,
|
|
26
28
|
checked: checked,
|
|
29
|
+
ariaLabel: stringProperty(element, 'ariaLabel'),
|
|
27
30
|
onCheckedChange: (event)=>setChecked(event.checked),
|
|
28
31
|
disabled: booleanProperty(element, 'disabled', false),
|
|
29
32
|
children: /*#__PURE__*/ jsx(ToggleSwitch.Control, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrimeToggleSwitch.js","sources":["../../../form/PrimeToggleSwitch.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 { useState } from 'react';\nimport { ToggleSwitch } from 'primereact/toggleswitch';\nimport { RegisteredComponentProps } from '@cratis/scene.react';\nimport { booleanProperty, stringProperty } from '../properties';\n\n/**\n * The `PrimeReact:toggleSwitch` component.\n *\n * The abstract name has always been `toggleSwitch` even while PrimeReact 10 called the component\n * `InputSwitch` - a Scene name follows what the thing is rather than what one library happens to call it\n * this major version - and v11 renaming it `ToggleSwitch` is the library catching up rather than the\n * package moving.\n *\n * `Root` renders the hidden checkbox that carries the state and the accessible name, and the visible\n * switch is `Control` plus the `Handle` that slides inside it. That is why `inputId` and not `id` is what\n * the label points at: the label has to reach the input, not the wrapper.\n */\nexport function PrimeToggleSwitch({ element }: RegisteredComponentProps) {\n const [checked, setChecked] = useState(booleanProperty(element, 'checked', false));\n const label = stringProperty(element, 'label');\n return (\n <div data-scene-id={element.id} className='flex items-center gap-2'>\n <ToggleSwitch.Root\n inputId={element.id}\n checked={checked}\n onCheckedChange={(event) => setChecked(event.checked)}\n disabled={booleanProperty(element, 'disabled', false)}>\n <ToggleSwitch.Control>\n <ToggleSwitch.Handle />\n </ToggleSwitch.Control>\n </ToggleSwitch.Root>\n {label !== undefined && <label htmlFor={element.id}>{label}</label>}\n </div>\n );\n}\n"],"names":["PrimeToggleSwitch","element","checked","setChecked","useState","booleanProperty","label","stringProperty","_jsxs","div","data-scene-id","id","className","_jsx","ToggleSwitch","Root","inputId","onCheckedChange","event","disabled","Control","Handle","undefined","htmlFor"],"mappings":"
|
|
1
|
+
{"version":3,"file":"PrimeToggleSwitch.js","sources":["../../../form/PrimeToggleSwitch.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 { useState } from 'react';\nimport { ToggleSwitch } from 'primereact/toggleswitch';\nimport { RegisteredComponentProps, useValueOutput } from '@cratis/scene.react';\nimport { booleanProperty, stringProperty } from '../properties';\n\n/**\n * The `PrimeReact:toggleSwitch` component.\n *\n * The abstract name has always been `toggleSwitch` even while PrimeReact 10 called the component\n * `InputSwitch` - a Scene name follows what the thing is rather than what one library happens to call it\n * this major version - and v11 renaming it `ToggleSwitch` is the library catching up rather than the\n * package moving.\n *\n * `Root` renders the hidden checkbox that carries the state and the accessible name, and the visible\n * switch is `Control` plus the `Handle` that slides inside it. That is why `inputId` and not `id` is what\n * the label points at: the label has to reach the input, not the wrapper.\n */\nexport function PrimeToggleSwitch({ element, bindingOutputs }: RegisteredComponentProps) {\n const [checked, setChecked] = useState(booleanProperty(element, 'checked', false));\n useValueOutput(bindingOutputs, checked);\n const label = stringProperty(element, 'label');\n return (\n <div data-scene-id={element.id} className='flex items-center gap-2'>\n <ToggleSwitch.Root\n inputId={element.id}\n checked={checked}\n ariaLabel={stringProperty(element, 'ariaLabel')}\n onCheckedChange={(event) => setChecked(event.checked)}\n disabled={booleanProperty(element, 'disabled', false)}>\n <ToggleSwitch.Control>\n <ToggleSwitch.Handle />\n </ToggleSwitch.Control>\n </ToggleSwitch.Root>\n {label !== undefined && <label htmlFor={element.id}>{label}</label>}\n </div>\n );\n}\n"],"names":["PrimeToggleSwitch","element","bindingOutputs","checked","setChecked","useState","booleanProperty","useValueOutput","label","stringProperty","_jsxs","div","data-scene-id","id","className","_jsx","ToggleSwitch","Root","inputId","ariaLabel","onCheckedChange","event","disabled","Control","Handle","undefined","htmlFor"],"mappings":";;;;;;AAQA;;;;;;;;;;;AAWC,IACM,SAASA,iBAAAA,CAAkB,EAAEC,OAAO,EAAEC,cAAc,EAA4B,EAAA;AACnF,IAAA,MAAM,CAACC,OAAAA,EAASC,UAAAA,CAAW,GAAGC,QAAAA,CAASC,eAAAA,CAAgBL,SAAS,SAAA,EAAW,KAAA,CAAA,CAAA;AAC3EM,IAAAA,cAAAA,CAAeL,cAAAA,EAAgBC,OAAAA,CAAAA;IAC/B,MAAMK,KAAAA,GAAQC,eAAeR,OAAAA,EAAS,OAAA,CAAA;AACtC,IAAA,qBACIS,IAAA,CAACC,KAAAA,EAAAA;AAAIC,QAAAA,eAAAA,EAAeX,QAAQY,EAAE;QAAEC,SAAAA,EAAU,yBAAA;;AACtC,0BAAAC,GAAA,CAACC,aAAaC,IAAI,EAAA;AACdC,gBAAAA,OAAAA,EAASjB,QAAQY,EAAE;gBACnBV,OAAAA,EAASA,OAAAA;AACTgB,gBAAAA,SAAAA,EAAWV,eAAeR,OAAAA,EAAS,WAAA,CAAA;AACnCmB,gBAAAA,eAAAA,EAAiB,CAACC,KAAAA,GAAUjB,UAAAA,CAAWiB,KAAAA,CAAMlB,OAAO,CAAA;gBACpDmB,QAAAA,EAAUhB,eAAAA,CAAgBL,SAAS,UAAA,EAAY,KAAA,CAAA;wCAC/Cc,GAAA,CAACC,aAAaO,OAAO,EAAA;4CACjBR,GAAA,CAACC,aAAaQ,MAAM,EAAA,EAAA;;;AAG3BhB,YAAAA,KAAAA,KAAUiB,2BAAaV,GAAA,CAACP,OAAAA,EAAAA;AAAMkB,gBAAAA,OAAAA,EAASzB,QAAQY,EAAE;AAAGL,gBAAAA,QAAAA,EAAAA;;;;AAGjE;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inputDescriptors.d.ts","sourceRoot":"","sources":["../../inputDescriptors.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,mBAAmB,EAAyC,MAAM,qBAAqB,CAAC;AAuBjG,eAAO,MAAM,0BAA0B,EAAE,mBAAmB,EAW3D,CAAC"}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { PropertyValueType } from '@cratis/scene.model';
|
|
2
|
+
import { valueOutputProperty, componentRegistryKey } from '@cratis/scene.react';
|
|
3
|
+
|
|
4
|
+
// Copyright (c) Cratis. All rights reserved.
|
|
5
|
+
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
6
|
+
const key = (name)=>componentRegistryKey('PrimeReact', name);
|
|
7
|
+
const common = [
|
|
8
|
+
{
|
|
9
|
+
path: 'ariaLabel',
|
|
10
|
+
label: 'Accessible name',
|
|
11
|
+
group: 'Accessibility',
|
|
12
|
+
valueType: PropertyValueType.String
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
path: 'disabled',
|
|
16
|
+
label: 'Disabled',
|
|
17
|
+
group: 'Behavior',
|
|
18
|
+
valueType: PropertyValueType.Boolean,
|
|
19
|
+
default: false
|
|
20
|
+
}
|
|
21
|
+
];
|
|
22
|
+
const placeholder = {
|
|
23
|
+
path: 'placeholder',
|
|
24
|
+
label: 'Placeholder',
|
|
25
|
+
group: 'Content',
|
|
26
|
+
valueType: PropertyValueType.String
|
|
27
|
+
};
|
|
28
|
+
const checked = {
|
|
29
|
+
path: 'checked',
|
|
30
|
+
label: 'Initially checked',
|
|
31
|
+
group: 'Content',
|
|
32
|
+
valueType: PropertyValueType.Boolean,
|
|
33
|
+
default: false
|
|
34
|
+
};
|
|
35
|
+
function input(name, displayName, valueType, properties = [
|
|
36
|
+
placeholder
|
|
37
|
+
]) {
|
|
38
|
+
const output = valueOutputProperty(valueType);
|
|
39
|
+
// A selection publishes the chosen option values; the item descriptor names them for a binding picker.
|
|
40
|
+
const value = valueType === PropertyValueType.Collection ? {
|
|
41
|
+
...output,
|
|
42
|
+
item: {
|
|
43
|
+
label: 'option value',
|
|
44
|
+
properties: []
|
|
45
|
+
}
|
|
46
|
+
} : output;
|
|
47
|
+
return {
|
|
48
|
+
component: key(name),
|
|
49
|
+
displayName,
|
|
50
|
+
properties: [
|
|
51
|
+
...properties,
|
|
52
|
+
...common,
|
|
53
|
+
value
|
|
54
|
+
]
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* The input widgets that publish what the user entered as their `value` output (Cratis/StudioIssues#156).
|
|
59
|
+
* A designer offers the output as a binding source; a command action maps it as `component.<id>.value`.
|
|
60
|
+
*/ const primeReactInputDescriptors = [
|
|
61
|
+
input('inputText', 'Text input', PropertyValueType.String),
|
|
62
|
+
input('inputTextarea', 'Text area', PropertyValueType.String),
|
|
63
|
+
input('password', 'Password', PropertyValueType.String),
|
|
64
|
+
input('inputNumber', 'Number input', PropertyValueType.Number),
|
|
65
|
+
input('calendar', 'Date picker', PropertyValueType.String),
|
|
66
|
+
input('dropdown', 'Dropdown', PropertyValueType.String),
|
|
67
|
+
input('multiSelect', 'Multi-select', PropertyValueType.Collection),
|
|
68
|
+
input('radioButton', 'Radio group', PropertyValueType.String, []),
|
|
69
|
+
input('checkbox', 'Checkbox', PropertyValueType.Boolean, [
|
|
70
|
+
checked,
|
|
71
|
+
{
|
|
72
|
+
path: 'label',
|
|
73
|
+
label: 'Label',
|
|
74
|
+
group: 'Content',
|
|
75
|
+
valueType: PropertyValueType.String
|
|
76
|
+
}
|
|
77
|
+
]),
|
|
78
|
+
input('toggleSwitch', 'Toggle switch', PropertyValueType.Boolean, [
|
|
79
|
+
checked
|
|
80
|
+
])
|
|
81
|
+
];
|
|
82
|
+
|
|
83
|
+
export { primeReactInputDescriptors };
|
|
84
|
+
//# sourceMappingURL=inputDescriptors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inputDescriptors.js","sources":["../../inputDescriptors.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 { ComponentDescriptor, PropertyDescriptor, PropertyValueType } from '@cratis/scene.model';\nimport { componentRegistryKey, valueOutputProperty } from '@cratis/scene.react';\n\nconst key = (name: string) => componentRegistryKey('PrimeReact', name);\n\nconst common: PropertyDescriptor[] = [\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n { path: 'disabled', label: 'Disabled', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n];\nconst placeholder: PropertyDescriptor = { path: 'placeholder', label: 'Placeholder', group: 'Content', valueType: PropertyValueType.String };\nconst checked: PropertyDescriptor = { path: 'checked', label: 'Initially checked', group: 'Content', valueType: PropertyValueType.Boolean, default: false };\n\nfunction input(name: string, displayName: string, valueType: PropertyValueType, properties: PropertyDescriptor[] = [placeholder]): ComponentDescriptor {\n const output = valueOutputProperty(valueType);\n // A selection publishes the chosen option values; the item descriptor names them for a binding picker.\n const value = valueType === PropertyValueType.Collection ? { ...output, item: { label: 'option value', properties: [] } } : output;\n return { component: key(name), displayName, properties: [...properties, ...common, value] };\n}\n\n/**\n * The input widgets that publish what the user entered as their `value` output (Cratis/StudioIssues#156).\n * A designer offers the output as a binding source; a command action maps it as `component.<id>.value`.\n */\nexport const primeReactInputDescriptors: ComponentDescriptor[] = [\n input('inputText', 'Text input', PropertyValueType.String),\n input('inputTextarea', 'Text area', PropertyValueType.String),\n input('password', 'Password', PropertyValueType.String),\n input('inputNumber', 'Number input', PropertyValueType.Number),\n input('calendar', 'Date picker', PropertyValueType.String),\n input('dropdown', 'Dropdown', PropertyValueType.String),\n input('multiSelect', 'Multi-select', PropertyValueType.Collection),\n input('radioButton', 'Radio group', PropertyValueType.String, []),\n input('checkbox', 'Checkbox', PropertyValueType.Boolean, [checked, { path: 'label', label: 'Label', group: 'Content', valueType: PropertyValueType.String }]),\n input('toggleSwitch', 'Toggle switch', PropertyValueType.Boolean, [checked]),\n];\n"],"names":["key","name","componentRegistryKey","common","path","label","group","valueType","PropertyValueType","String","Boolean","default","placeholder","checked","input","displayName","properties","output","valueOutputProperty","value","Collection","item","component","primeReactInputDescriptors","Number"],"mappings":";;;AAAA;AACA;AAKA,MAAMA,GAAAA,GAAM,CAACC,IAAAA,GAAiBC,oBAAAA,CAAqB,YAAA,EAAcD,IAAAA,CAAAA;AAEjE,MAAME,MAAAA,GAA+B;AACjC,IAAA;QAAEC,IAAAA,EAAM,WAAA;QAAaC,KAAAA,EAAO,iBAAA;QAAmBC,KAAAA,EAAO,eAAA;AAAiBC,QAAAA,SAAAA,EAAWC,kBAAkBC;AAAO,KAAA;AAC3G,IAAA;QAAEL,IAAAA,EAAM,UAAA;QAAYC,KAAAA,EAAO,UA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,KAAAA,CAAM,UAAA,EAAY,UAAA,EAAYN,iBAAAA,CAAkBC,MAAM,CAAA;IACtDK,KAAAA,CAAM,aAAA,EAAe,cAAA,EAAgBN,iBAAAA,CAAkBgB,MAAM,CAAA;IAC7DV,KAAAA,CAAM,UAAA,EAAY,aAAA,EAAeN,iBAAAA,CAAkBC,MAAM,CAAA;IACzDK,KAAAA,CAAM,UAAA,EAAY,UAAA,EAAYN,iBAAAA,CAAkBC,MAAM,CAAA;IACtDK,KAAAA,CAAM,aAAA,EAAe,cAAA,EAAgBN,iBAAAA,CAAkBY,UAAU,CAAA;AACjEN,IAAAA,KAAAA,CAAM,aAAA,EAAe,aAAA,EAAeN,iBAAAA,CAAkBC,MAAM,EAAE,EAAE,CAAA;AAChEK,IAAAA,KAAAA,CAAM,UAAA,EAAY,UAAA,EAAYN,iBAAAA,CAAkBE,OAAO,EAAE;AAACG,QAAAA,OAAAA;AAAS,QAAA;YAAET,IAAAA,EAAM,OAAA;YAASC,KAAAA,EAAO,OAAA;YAASC,KAAAA,EAAO,SAAA;AAAWC,YAAAA,SAAAA,EAAWC,kBAAkBC;AAAO;AAAE,KAAA,CAAA;AAC5JK,IAAAA,KAAAA,CAAM,cAAA,EAAgB,eAAA,EAAiBN,iBAAAA,CAAkBE,OAAO,EAAE;AAACG,QAAAA;AAAQ,KAAA;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"primeReactDescriptors.d.ts","sourceRoot":"","sources":["../../primeReactDescriptors.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,mBAAmB,EAAqB,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"primeReactDescriptors.d.ts","sourceRoot":"","sources":["../../primeReactDescriptors.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,mBAAmB,EAAqB,MAAM,qBAAqB,CAAC;AAY7E,eAAO,MAAM,qBAAqB,EAAE,mBAAmB,EAiGtD,CAAC"}
|
|
@@ -19,11 +19,13 @@ import { TreeTableSelectionMode } from './data/TreeTableSelectionMode.js';
|
|
|
19
19
|
import './file/FileUploadContext.js';
|
|
20
20
|
import { FileUploadMode } from './file/FileUploadMode.js';
|
|
21
21
|
import 'primereact/fileupload';
|
|
22
|
+
import { primeReactInputDescriptors } from './inputDescriptors.js';
|
|
22
23
|
|
|
23
24
|
// Copyright (c) Cratis. All rights reserved.
|
|
24
25
|
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
25
26
|
const key = (name)=>componentRegistryKey('PrimeReact', name);
|
|
26
27
|
/** Design-time descriptors for PrimeReact controls whose authored data has structured configuration. */ const primeReactDescriptors = [
|
|
28
|
+
...primeReactInputDescriptors,
|
|
27
29
|
{
|
|
28
30
|
component: key('chart'),
|
|
29
31
|
displayName: 'Chart',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"primeReactDescriptors.js","sources":["../../primeReactDescriptors.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 { ComponentDescriptor, PropertyValueType } from '@cratis/scene.model';\nimport { componentRegistryKey } from '@cratis/scene.react';\nimport { chartTypeChoices } from './chart/chartTypeChoices';\nimport { legacyEnumerationChoices } from './legacyEnumerationChoices';\nimport { ChartType } from './chart';\nimport { TreeTableSelectionMode } from './data';\nimport { FileUploadMode } from './file';\n\nconst key = (name: string) => componentRegistryKey('PrimeReact', name);\n\n/** Design-time descriptors for PrimeReact controls whose authored data has structured configuration. */\nexport const primeReactDescriptors: ComponentDescriptor[] = [\n {\n component: key('chart'),\n displayName: 'Chart',\n description: 'A Chart.js chart. Legacy numeric types are rendered without changing stored data; new documents use stable type names. The host application must install chart.js.',\n properties: [\n {\n path: 'type', label: 'Type', group: 'Chart', valueType: PropertyValueType.Enum, default: ChartType.Bar,\n choices: chartTypeChoices,\n },\n { path: 'data', label: 'Data', group: 'Data', valueType: PropertyValueType.Json, description: 'The Chart.js data object, including labels and datasets in their authored order.' },\n { path: 'options', label: 'Options', group: 'Chart', valueType: PropertyValueType.Json, description: 'The Chart.js options object.' },\n { path: 'emptyLabel', label: 'No data label', group: 'Accessibility', valueType: PropertyValueType.String, default: 'No chart data', description: 'Shown instead of the chart while it has no data points. Data is never invented.' },\n { path: 'responsive', label: 'Responsive', group: 'Layout', valueType: PropertyValueType.Boolean, default: true },\n { path: 'style', label: 'Style', group: 'Layout', valueType: PropertyValueType.Json, description: 'The CSS style object applied to the chart surface.' },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('fileUpload'),\n displayName: 'File upload',\n description: 'An accessible file picker and drop zone. A host provides its upload effect, or the files are posted to the authored server URL. The URL must be on the page\\'s own origin unless the host allows another one.',\n properties: [\n {\n path: 'mode', label: 'Mode', group: 'Behavior', valueType: PropertyValueType.Enum, default: FileUploadMode.Advanced,\n choices: legacyEnumerationChoices(FileUploadMode, { [FileUploadMode.Advanced]: 'Advanced', [FileUploadMode.Basic]: 'Basic', [FileUploadMode.Auto]: 'Automatic' }),\n },\n { path: 'url', label: 'Server URL', group: 'Upload', valueType: PropertyValueType.String, description: 'Where the files are posted. Only the origin of the page, or an origin the host allows, is accepted; anything else is refused and nothing is sent.' },\n { path: 'name', label: 'Request field name', group: 'Upload', valueType: PropertyValueType.String, default: 'files' },\n { path: 'accept', label: 'Accepted MIME types', group: 'Upload', valueType: PropertyValueType.String },\n { path: 'multiple', label: 'Allow multiple files', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'maxFileSize', label: 'Maximum file size', group: 'Upload', valueType: PropertyValueType.Number, constraints: { minimum: 0, integer: true } },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('dataScroller'),\n displayName: 'Data scroller',\n description: 'A list that loads a chunk at a time as its end is reached. Items are strings, numbers or records, plus any child elements in the items slot; serialized legacy UI elements are refused.',\n properties: [\n { path: 'items', label: 'Items', group: 'Data', valueType: PropertyValueType.Json, description: 'Strings, numbers or records. A record is titled by its label, title, name, text or header field.' },\n { path: 'rows', label: 'Rows per load', group: 'Behavior', valueType: PropertyValueType.Number, default: 10, constraints: { minimum: 1, integer: true } },\n { path: 'inline', label: 'Scroll inline', group: 'Layout', valueType: PropertyValueType.Boolean, default: false, description: 'Scroll inside the control (true) or load as the page scrolls the end of the list into view (false).' },\n { path: 'scrollHeight', label: 'Inline scroll height', group: 'Layout', valueType: PropertyValueType.Number, constraints: { minimum: 1 }, description: 'The height in pixels of an inline scroller. 320 when omitted.' },\n { path: 'emptyLabel', label: 'No items label', group: 'Accessibility', valueType: PropertyValueType.String, default: 'No items to show' },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('treeTable'),\n displayName: 'Tree table',\n description: 'A hierarchical table with authored columns, selection, and optional pagination. Items are nodes (strings, numbers or records with key, label, data, children); serialized legacy UI elements are refused.',\n properties: [\n { path: 'columns', label: 'Columns', group: 'Data', valueType: PropertyValueType.Json, description: 'Column definitions with field and header, or nested column elements. Inferred from the first row when absent.' },\n { path: 'items', label: 'Items', group: 'Data', valueType: PropertyValueType.Json, description: 'The nodes: strings, numbers, or records with key, label, data, children, expanded and selectable.' },\n {\n path: 'selectionMode', label: 'Selection mode', group: 'Behavior', valueType: PropertyValueType.Enum, default: TreeTableSelectionMode.None,\n choices: legacyEnumerationChoices(TreeTableSelectionMode, { [TreeTableSelectionMode.None]: 'None', [TreeTableSelectionMode.Single]: 'Single', [TreeTableSelectionMode.Multiple]: 'Multiple', [TreeTableSelectionMode.Checkbox]: 'Checkbox' }),\n },\n { path: 'selection', label: 'Selection', group: 'Behavior', valueType: PropertyValueType.Json, description: 'The selected node keys: a key, an array of keys or { key } objects, or PrimeReact\\'s key map.' },\n { path: 'paginator', label: 'Show pagination', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'rows', label: 'Rows per page', group: 'Behavior', valueType: PropertyValueType.Number, default: 10, constraints: { minimum: 1, integer: true } },\n { path: 'emptyLabel', label: 'No records label', group: 'Accessibility', valueType: PropertyValueType.String, default: 'No records found' },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('editor'),\n displayName: 'Rich text editor',\n description: 'A rich-text HTML editor. Editing needs the host to provide Quill (QuillLoaderProvider); without it the content is shown read-only. The HTML is sanitized before it is shown.',\n properties: [\n { path: 'value', label: 'HTML value', group: 'Content', valueType: PropertyValueType.String },\n { path: 'placeholder', label: 'Placeholder', group: 'Content', valueType: PropertyValueType.String },\n { path: 'showHeader', label: 'Show toolbar', group: 'Behavior', valueType: PropertyValueType.Boolean, default: true },\n { path: 'readOnly', label: 'Read only', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('multiStateCheckbox'),\n displayName: 'Multi-state checkbox',\n description: 'An accessible button that cycles through its authored states in order, showing the current state as a checkbox-style glyph.',\n properties: [\n { path: 'value', label: 'Value', group: 'State', valueType: PropertyValueType.Json, description: 'The selected value. It may be null when the empty state is enabled.' },\n { path: 'options', label: 'Options', group: 'State', valueType: PropertyValueType.Json, description: 'The ordered state options. Each may provide label, value, and icon fields.' },\n { path: 'optionLabel', label: 'Option label field', group: 'State', valueType: PropertyValueType.String, default: 'label' },\n { path: 'optionValue', label: 'Option value field', group: 'State', valueType: PropertyValueType.String, default: 'value' },\n { path: 'empty', label: 'Allow empty state', group: 'State', valueType: PropertyValueType.Boolean, default: true },\n { path: 'emptyLabel', label: 'Empty state label', group: 'Accessibility', valueType: PropertyValueType.String, default: 'No selection' },\n { path: 'icons', label: 'Icons', group: 'Appearance', valueType: PropertyValueType.Json, description: 'Icons aligned with the options, or keyed by their values. Each is a PrimeIcons class name or a qualified icon reference. Icons inside this value are not tracked by the icon library diagnostics; use the empty state icon where a tracked icon is needed.' },\n { path: 'emptyIcon', label: 'Empty state icon', group: 'Appearance', valueType: PropertyValueType.Icon },\n { path: 'readOnly', label: 'Read only', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'disabled', label: 'Disabled', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n];\n"],"names":["key","name","componentRegistryKey","primeReactDescriptors","component","displayName","description","properties","path","label","group","valueType","PropertyValueType","Enum","default","ChartType","Bar","choices","chartTypeChoices","Json","String","Boolean","FileUploadMode","Advanced","legacyEnumerationChoices","Basic","Auto","Number","constraints","minimum","integer","TreeTableSelectionMode","None","Single","Multiple","Checkbox","Icon"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AAUA,MAAMA,GAAAA,GAAM,CAACC,IAAAA,GAAiBC,oBAAAA,CAAqB,YAAA,EAAcD,IAAAA,CAAAA;AAEjE,yGACO,MAAME,qBAAAA,GAA+C;AACxD,IAAA;AACIC,QAAAA,SAAAA,EAAWJ,GAAAA,CAAI,OAAA,CAAA;QACfK,WAAAA,EAAa,OAAA;QACbC,WAAAA,EAAa,oKAAA;QACbC,UAAAA,EAAY;AACR,YAAA;gBACIC,IAAAA,EAAM,MAAA;gBAAQC,KAAAA,EAAO,MAAA;gBAAQC,KAAAA,EAAO,OAAA;AAASC,gBAAAA,SAAAA,EAAWC,kBAAkBC,IAAI;AAAEC,gBAAAA,OAAAA,EAASC,UAAUC,GAAG;gBACtGC,OAAAA,EAASC;AACb,aAAA;AACA,YAAA;gBAAEV,IAAAA,EAAM,MAAA;gBAAQC,KAAAA,EAAO,MAAA;gBAAQC,KAAAA,EAAO,MAAA;AAAQC,gBAAAA,SAAAA,EAAWC,kBAAkBO,IAAI;gBAAEb,WAAAA,EAAa;AAAmF,aAAA;AACjL,YAAA;gBAAEE,IAAAA,EAAM,SAAA;gBAAWC,KAAAA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EAAO,eAAA;AAAiBC,gBAAAA,SAAAA,EAAWC,kBAAkBQ;AAAO;AAC9G;AACL;;;"}
|
|
1
|
+
{"version":3,"file":"primeReactDescriptors.js","sources":["../../primeReactDescriptors.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 { ComponentDescriptor, PropertyValueType } from '@cratis/scene.model';\nimport { componentRegistryKey } from '@cratis/scene.react';\nimport { chartTypeChoices } from './chart/chartTypeChoices';\nimport { legacyEnumerationChoices } from './legacyEnumerationChoices';\nimport { ChartType } from './chart';\nimport { TreeTableSelectionMode } from './data';\nimport { FileUploadMode } from './file';\nimport { primeReactInputDescriptors } from './inputDescriptors';\n\nconst key = (name: string) => componentRegistryKey('PrimeReact', name);\n\n/** Design-time descriptors for PrimeReact controls whose authored data has structured configuration. */\nexport const primeReactDescriptors: ComponentDescriptor[] = [\n ...primeReactInputDescriptors,\n {\n component: key('chart'),\n displayName: 'Chart',\n description: 'A Chart.js chart. Legacy numeric types are rendered without changing stored data; new documents use stable type names. The host application must install chart.js.',\n properties: [\n {\n path: 'type', label: 'Type', group: 'Chart', valueType: PropertyValueType.Enum, default: ChartType.Bar,\n choices: chartTypeChoices,\n },\n { path: 'data', label: 'Data', group: 'Data', valueType: PropertyValueType.Json, description: 'The Chart.js data object, including labels and datasets in their authored order.' },\n { path: 'options', label: 'Options', group: 'Chart', valueType: PropertyValueType.Json, description: 'The Chart.js options object.' },\n { path: 'emptyLabel', label: 'No data label', group: 'Accessibility', valueType: PropertyValueType.String, default: 'No chart data', description: 'Shown instead of the chart while it has no data points. Data is never invented.' },\n { path: 'responsive', label: 'Responsive', group: 'Layout', valueType: PropertyValueType.Boolean, default: true },\n { path: 'style', label: 'Style', group: 'Layout', valueType: PropertyValueType.Json, description: 'The CSS style object applied to the chart surface.' },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('fileUpload'),\n displayName: 'File upload',\n description: 'An accessible file picker and drop zone. A host provides its upload effect, or the files are posted to the authored server URL. The URL must be on the page\\'s own origin unless the host allows another one.',\n properties: [\n {\n path: 'mode', label: 'Mode', group: 'Behavior', valueType: PropertyValueType.Enum, default: FileUploadMode.Advanced,\n choices: legacyEnumerationChoices(FileUploadMode, { [FileUploadMode.Advanced]: 'Advanced', [FileUploadMode.Basic]: 'Basic', [FileUploadMode.Auto]: 'Automatic' }),\n },\n { path: 'url', label: 'Server URL', group: 'Upload', valueType: PropertyValueType.String, description: 'Where the files are posted. Only the origin of the page, or an origin the host allows, is accepted; anything else is refused and nothing is sent.' },\n { path: 'name', label: 'Request field name', group: 'Upload', valueType: PropertyValueType.String, default: 'files' },\n { path: 'accept', label: 'Accepted MIME types', group: 'Upload', valueType: PropertyValueType.String },\n { path: 'multiple', label: 'Allow multiple files', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'maxFileSize', label: 'Maximum file size', group: 'Upload', valueType: PropertyValueType.Number, constraints: { minimum: 0, integer: true } },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('dataScroller'),\n displayName: 'Data scroller',\n description: 'A list that loads a chunk at a time as its end is reached. Items are strings, numbers or records, plus any child elements in the items slot; serialized legacy UI elements are refused.',\n properties: [\n { path: 'items', label: 'Items', group: 'Data', valueType: PropertyValueType.Json, description: 'Strings, numbers or records. A record is titled by its label, title, name, text or header field.' },\n { path: 'rows', label: 'Rows per load', group: 'Behavior', valueType: PropertyValueType.Number, default: 10, constraints: { minimum: 1, integer: true } },\n { path: 'inline', label: 'Scroll inline', group: 'Layout', valueType: PropertyValueType.Boolean, default: false, description: 'Scroll inside the control (true) or load as the page scrolls the end of the list into view (false).' },\n { path: 'scrollHeight', label: 'Inline scroll height', group: 'Layout', valueType: PropertyValueType.Number, constraints: { minimum: 1 }, description: 'The height in pixels of an inline scroller. 320 when omitted.' },\n { path: 'emptyLabel', label: 'No items label', group: 'Accessibility', valueType: PropertyValueType.String, default: 'No items to show' },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('treeTable'),\n displayName: 'Tree table',\n description: 'A hierarchical table with authored columns, selection, and optional pagination. Items are nodes (strings, numbers or records with key, label, data, children); serialized legacy UI elements are refused.',\n properties: [\n { path: 'columns', label: 'Columns', group: 'Data', valueType: PropertyValueType.Json, description: 'Column definitions with field and header, or nested column elements. Inferred from the first row when absent.' },\n { path: 'items', label: 'Items', group: 'Data', valueType: PropertyValueType.Json, description: 'The nodes: strings, numbers, or records with key, label, data, children, expanded and selectable.' },\n {\n path: 'selectionMode', label: 'Selection mode', group: 'Behavior', valueType: PropertyValueType.Enum, default: TreeTableSelectionMode.None,\n choices: legacyEnumerationChoices(TreeTableSelectionMode, { [TreeTableSelectionMode.None]: 'None', [TreeTableSelectionMode.Single]: 'Single', [TreeTableSelectionMode.Multiple]: 'Multiple', [TreeTableSelectionMode.Checkbox]: 'Checkbox' }),\n },\n { path: 'selection', label: 'Selection', group: 'Behavior', valueType: PropertyValueType.Json, description: 'The selected node keys: a key, an array of keys or { key } objects, or PrimeReact\\'s key map.' },\n { path: 'paginator', label: 'Show pagination', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'rows', label: 'Rows per page', group: 'Behavior', valueType: PropertyValueType.Number, default: 10, constraints: { minimum: 1, integer: true } },\n { path: 'emptyLabel', label: 'No records label', group: 'Accessibility', valueType: PropertyValueType.String, default: 'No records found' },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('editor'),\n displayName: 'Rich text editor',\n description: 'A rich-text HTML editor. Editing needs the host to provide Quill (QuillLoaderProvider); without it the content is shown read-only. The HTML is sanitized before it is shown.',\n properties: [\n { path: 'value', label: 'HTML value', group: 'Content', valueType: PropertyValueType.String },\n { path: 'placeholder', label: 'Placeholder', group: 'Content', valueType: PropertyValueType.String },\n { path: 'showHeader', label: 'Show toolbar', group: 'Behavior', valueType: PropertyValueType.Boolean, default: true },\n { path: 'readOnly', label: 'Read only', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n {\n component: key('multiStateCheckbox'),\n displayName: 'Multi-state checkbox',\n description: 'An accessible button that cycles through its authored states in order, showing the current state as a checkbox-style glyph.',\n properties: [\n { path: 'value', label: 'Value', group: 'State', valueType: PropertyValueType.Json, description: 'The selected value. It may be null when the empty state is enabled.' },\n { path: 'options', label: 'Options', group: 'State', valueType: PropertyValueType.Json, description: 'The ordered state options. Each may provide label, value, and icon fields.' },\n { path: 'optionLabel', label: 'Option label field', group: 'State', valueType: PropertyValueType.String, default: 'label' },\n { path: 'optionValue', label: 'Option value field', group: 'State', valueType: PropertyValueType.String, default: 'value' },\n { path: 'empty', label: 'Allow empty state', group: 'State', valueType: PropertyValueType.Boolean, default: true },\n { path: 'emptyLabel', label: 'Empty state label', group: 'Accessibility', valueType: PropertyValueType.String, default: 'No selection' },\n { path: 'icons', label: 'Icons', group: 'Appearance', valueType: PropertyValueType.Json, description: 'Icons aligned with the options, or keyed by their values. Each is a PrimeIcons class name or a qualified icon reference. Icons inside this value are not tracked by the icon library diagnostics; use the empty state icon where a tracked icon is needed.' },\n { path: 'emptyIcon', label: 'Empty state icon', group: 'Appearance', valueType: PropertyValueType.Icon },\n { path: 'readOnly', label: 'Read only', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'disabled', label: 'Disabled', group: 'Behavior', valueType: PropertyValueType.Boolean, default: false },\n { path: 'ariaLabel', label: 'Accessible name', group: 'Accessibility', valueType: PropertyValueType.String },\n ],\n },\n];\n"],"names":["key","name","componentRegistryKey","primeReactDescriptors","primeReactInputDescriptors","component","displayName","description","properties","path","label","group","valueType","PropertyValueType","Enum","default","ChartType","Bar","choices","chartTypeChoices","Json","String","Boolean","FileUploadMode","Advanced","legacyEnumerationChoices","Basic","Auto","Number","constraints","minimum","integer","TreeTableSelectionMode","None","Single","Multiple","Checkbox","Icon"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AAWA,MAAMA,GAAAA,GAAM,CAACC,IAAAA,GAAiBC,oBAAAA,CAAqB,YAAA,EAAcD,IAAAA,CAAAA;AAEjE,yGACO,MAAME,qBAAAA,GAA+C;AACrDC,IAAAA,GAAAA,0BAAAA;AACH,IAAA;AACIC,QAAAA,SAAAA,EAAWL,GAAAA,CAAI,OAAA,CAAA;QACfM,WAAAA,EAAa,OAAA;QACbC,WAAAA,EAAa,oKAAA;QACbC,UAAAA,EAAY;AACR,YAAA;gBACIC,IAAAA,EAAM,MAAA;gBAAQC,KAAAA,EAAO,MAAA;gBAAQC,KAAAA,EAAO,OAAA;AAASC,gBAAAA,SAAAA,EAAWC,kBAAkBC,IAAI;AAAEC,gBAAAA,OAAAA,EAASC,UAAUC,GAAG;gBACtGC,OAAAA,EAASC;AACb,aAAA;AACA,YAAA;gBAAEV,IAAAA,EAAM,MAAA;gBAAQC,KAAAA,EAAO,MAAA;gBAAQC,KAAAA,EAAO,MAAA;AAAQC,gBAAAA,SAAAA,EAAWC,kBAAkBO,IAAI;gBAAEb,WAAAA,EAAa;AAAmF,aAAA;AACjL,YAAA;gBAAEE,IAAAA,EAAM,SAAA;gBAAWC,KAAAA,EAAO,SAAA;gBAAWC,KAAAA,EAAO,OAAA;AAASC,gBAAAA,SAAAA,EAAWC,kBAAkBO,IAAI;gBAAEb,WAAAA,EAAa;AAA+B,aAAA;AACpI,YAAA;gBAAEE,IAAAA,EAAM,YAAA;gBAAcC,KAAAA,EAAO,eAAA;gBAAiBC,KAAAA,EAAO,eAAA;AAAiBC,gBAAAA,SAAAA,EAAWC,kBAAkBQ,MAAM;gBAAEN,OAAAA,EAAS,eAAA;gBAAiBR,WAAAA,EAAa;AAAkF,aAAA;AACpO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