@pega/cosmos-react-build 9.0.0-build.14.0 → 9.0.0-build.14.10

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.
@@ -1 +1 @@
1
- {"version":3,"file":"DynamicInput.d.ts","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.tsx"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAU,MAAM,sBAAsB,CAAC;0BAwI5F,CAAC,SAAS,MAAM,WAChB,aAAa,SAAS,sBAAsB,CAAC,CAAC,CAAC,8BAC/C,SAAS,SAAS,MAAM,WACxB,mBAAmB,SAAS,MAAM,WAClC,eAAe,SAAS,MAAM,kBAEvB,iBAAiB,CAAC,CAAC,EAAE,aAAa,EAAE,SAAS,EAAE,mBAAmB,EAAE,eAAe,CAAC,KACxF,GAAG,CAAC,OAAO,GAAG,IAAI;;;AAEvB,wBAAiE"}
1
+ {"version":3,"file":"DynamicInput.d.ts","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.tsx"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAU,MAAM,sBAAsB,CAAC;0BA6I5F,CAAC,SAAS,MAAM,WAChB,aAAa,SAAS,sBAAsB,CAAC,CAAC,CAAC,8BAC/C,SAAS,SAAS,MAAM,WACxB,mBAAmB,SAAS,MAAM,WAClC,eAAe,SAAS,MAAM,kBAEvB,iBAAiB,CAAC,CAAC,EAAE,aAAa,EAAE,SAAS,EAAE,mBAAmB,EAAE,eAAe,CAAC,KACxF,GAAG,CAAC,OAAO,GAAG,IAAI;;;AAEvB,wBAAiE"}
@@ -5,7 +5,7 @@ import { StyledExpressionControl, StyledDynamicInput } from './DynamicInput.styl
5
5
  import SourceButton from './SourceButton';
6
6
  import { getCurrentSource, getSourceIcon } from './utils';
7
7
  import { getDynamicInputTestIds } from './DynamicInput.test-ids';
8
- const DynamicInput = forwardRef(function DynamicInput({ testId, label: labelProp, sources, onSourceChange, controls, required, hideSourceButton, ...restProps }, ref) {
8
+ const DynamicInput = forwardRef(function DynamicInput({ testId, label: labelProp, sources, onSourceChange, controls, required, hideSourceButton, disabled, readOnly, ...restProps }, ref) {
9
9
  const testIds = useTestIds(testId, getDynamicInputTestIds);
10
10
  const inputUid = useUID();
11
11
  const t = useI18n();
@@ -43,7 +43,7 @@ const DynamicInput = forwardRef(function DynamicInput({ testId, label: labelProp
43
43
  const { props, component: Component } = controls.fieldReference;
44
44
  control = (_jsx(Component, { ...props, id: inputUid, "data-testid": testIds.control, required: required }));
45
45
  }
46
- return (_jsxs(ThemeOverride, { theme: { base: { 'icon-set': 'streamline' } }, children: [_jsx(FormField, { label: label, labelFor: inputUid, required: required, ...restProps, ref: ref, testId: testIds.field, children: _jsxs(StyledDynamicInput, { children: [_jsx(_Fragment, { children: hideSourceButton ? null : (_jsx(SourceButton, { testId: testIds.menu, sources: sources, constantFormat: controls.constant?.props.format, icon: currentSource
46
+ return (_jsxs(ThemeOverride, { theme: { base: { 'icon-set': 'streamline' } }, children: [_jsx(FormField, { label: label, labelFor: inputUid, required: required, ...restProps, ref: ref, testId: testIds.field, disabled: disabled, readOnly: readOnly, children: _jsxs(StyledDynamicInput, { disabled: disabled, children: [_jsx(_Fragment, { children: hideSourceButton ? null : (_jsx(SourceButton, { testId: testIds.menu, sources: sources, constantFormat: controls.constant?.props.format, icon: currentSource
47
47
  ? getSourceIcon({
48
48
  source: currentSource,
49
49
  format: currentSource === 'Constant' ? controls.constant?.props.format : undefined
@@ -60,7 +60,7 @@ const DynamicInput = forwardRef(function DynamicInput({ testId, label: labelProp
60
60
  }), set: 'streamline' })),
61
61
  selected: config.selected
62
62
  };
63
- }), onSourceChange: onSourceChange, "aria-describedby": `${inputUid}-selected-source` })) }), control] }) }), _jsx(VisuallyHiddenText, { id: `${inputUid}-selected-source`, children: currentSource ? t('selected_noun', [sourceLabels[currentSource]]) : '' })] }));
63
+ }), onSourceChange: onSourceChange, "aria-describedby": `${inputUid}-selected-source`, disabled: disabled || readOnly })) }), control] }) }), _jsx(VisuallyHiddenText, { id: `${inputUid}-selected-source`, children: currentSource ? t('selected_noun', [sourceLabels[currentSource]]) : '' })] }));
64
64
  });
65
65
  export default withTestIds(DynamicInput, getDynamicInputTestIds);
66
66
  //# sourceMappingURL=DynamicInput.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"DynamicInput.js","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAGnC,OAAO,EACL,aAAa,EACb,OAAO,EACP,UAAU,EACV,MAAM,EACN,IAAI,EACJ,kBAAkB,EAClB,SAAS,EACT,WAAW,EACZ,MAAM,yBAAyB,CAAC;AAGjC,OAAO,EAAE,uBAAuB,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AACpF,OAAO,YAAY,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAC1D,OAAO,EAAE,sBAAsB,EAAE,MAAM,yBAAyB,CAAC;AAEjE,MAAM,YAAY,GAAG,UAAU,CAAC,SAAS,YAAY,CAOnD,EACE,MAAM,EACN,KAAK,EAAE,SAAS,EAChB,OAAO,EACP,cAAc,EACd,QAAQ,EACR,QAAQ,EACR,gBAAgB,EAChB,GAAG,SAAS,EAGb,EACD,GAAgG;IAEhG,MAAM,OAAO,GAAG,UAAU,CAAC,MAAM,EAAE,sBAAsB,CAAC,CAAC;IAC3D,MAAM,QAAQ,GAAG,MAAM,EAAE,CAAC;IAC1B,MAAM,CAAC,GAAG,OAAO,EAAE,CAAC;IAEpB,MAAM,KAAK,GAAG,SAAS,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC;IACtC,MAAM,aAAa,GAAG,gBAAgB,CAAC,OAAO,CAAC,CAAC;IAChD,MAAM,cAAc,GA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Z,MAAM,EAAE,aAAa;wCACrB,MAAM,EACJ,aAAa,KAAK,UAAU,CAAC,CAAC,CAAC,QAAQ,CAAC,QAAQ,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS;qCAC7E,CAAC;oCACJ,CAAC,CAAC,SAAS,EAEf,SAAS,EAAE,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE;oCAC9B,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC;oCAEzB,OAAO;wCACL,EAAE,EAAE,IAAI;wCACR,OAAO,EAAE,YAAY,CAAC,MAAM,CAAC,IAAI,CAAC;wCAClC,SAAS,EAAE,CAAC,kBAAkB,CAAC,IAAI,CAAC,CAAC;wCACrC,MAAM,EAAE,CACN,KAAC,IAAI,IACH,IAAI,EAAE,aAAa,CAAC;gDAClB,MAAM,EAAE,IAAI;gDACZ,MAAM,EAAE,IAAI,KAAK,UAAU,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,SAAS;6CACzD,CAAC,EACF,GAAG,EAAC,YAAY,GAChB,CACH;wCACD,QAAQ,EAAE,MAAM,CAAC,QAAQ;qCAC1B,CAAC;gCACJ,CAAC,CAAC,EACF,cAAc,EAAE,cAAc,sBACZ,GAAG,QAAQ,kBAAkB,GAC/C,CACH,GACA,EACF,OAAO,IACW,GACX,EAEZ,KAAC,kBAAkB,IAAC,EAAE,EAAE,GAAG,QAAQ,kBAAkB,YAClD,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,eAAe,EAAE,CAAC,YAAY,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,GACpD,IACP,CACjB,CAAC;AACJ,CAAC,CAQsB,CAAC;AAExB,eAAe,WAAW,CAAC,YAAY,EAAE,sBAAsB,CAAC,CAAC","sourcesContent":["import { forwardRef } from 'react';\nimport type { PropsWithoutRef } from 'react';\n\nimport {\n ThemeOverride,\n useI18n,\n useTestIds,\n useUID,\n Icon,\n VisuallyHiddenText,\n FormField,\n withTestIds\n} from '@pega/cosmos-react-core';\n\nimport type { ConstantComponentProps, DynamicInputProps, Source } from './DynamicInput.types';\nimport { StyledExpressionControl, StyledDynamicInput } from './DynamicInput.styles';\nimport SourceButton from './SourceButton';\nimport { getCurrentSource, getSourceIcon } from './utils';\nimport { getDynamicInputTestIds } from './DynamicInput.test-ids';\n\nconst DynamicInput = forwardRef(function DynamicInput<\n T extends object,\n ConstantProps extends ConstantComponentProps<T> = ConstantComponentProps<T>,\n RuleProps extends object = object,\n FieldReferenceProps extends object = object,\n ExpressionProps extends object = object\n>(\n {\n testId,\n label: labelProp,\n sources,\n onSourceChange,\n controls,\n required,\n hideSourceButton,\n ...restProps\n }: PropsWithoutRef<\n DynamicInputProps<T, ConstantProps, RuleProps, FieldReferenceProps, ExpressionProps>\n >,\n ref: DynamicInputProps<T, ConstantProps, RuleProps, FieldReferenceProps, ExpressionProps>['ref']\n) {\n const testIds = useTestIds(testId, getDynamicInputTestIds);\n const inputUid = useUID();\n const t = useI18n();\n\n const label = labelProp ?? t('value');\n const currentSource = getCurrentSource(sources);\n const constantFormat = controls.constant?.props.format;\n const sourceLabels: { [key in Source]: string } = {\n Constant: t('constant_label', [\n constantFormat ? t(`dynamicInput_format_${constantFormat}`) : ''\n ]),\n Expression: t('expression_label'),\n FieldReference: t('field_reference_label'),\n Rule: t('rule_label')\n };\n const sourceDescriptions: { [key in Source]: string } = {\n Constant: t('constant_description'),\n Expression: t('expression_description'),\n FieldReference: t('field_reference_description'),\n Rule: t('rule_description')\n };\n\n let control: JSX.Element = <>{null}</>;\n\n if (currentSource === 'Constant' && controls.constant) {\n const { props, component: Component } = controls.constant;\n control = (\n <Component {...props} id={inputUid} data-testid={testIds.control} required={required} />\n );\n } else if (currentSource === 'Rule' && controls.rule) {\n const { props, component: Component } = controls.rule;\n control = (\n <Component {...props} id={inputUid} data-testid={testIds.control} required={required} />\n );\n } else if (currentSource === 'Expression' && controls.expression) {\n const { props, component: Component } = controls.expression;\n\n control = (\n <StyledExpressionControl container>\n <Component {...props} id={inputUid} data-testid={testIds.control} required={required} />\n </StyledExpressionControl>\n );\n } else if (currentSource === 'FieldReference' && controls.fieldReference) {\n const { props, component: Component } = controls.fieldReference;\n control = (\n <Component {...props} id={inputUid} data-testid={testIds.control} required={required} />\n );\n }\n\n return (\n <ThemeOverride theme={{ base: { 'icon-set': 'streamline' } }}>\n <FormField\n label={label}\n labelFor={inputUid}\n required={required}\n {...restProps}\n ref={ref}\n testId={testIds.field}\n >\n <StyledDynamicInput>\n <>\n {hideSourceButton ? null : (\n <SourceButton\n testId={testIds.menu}\n sources={sources}\n constantFormat={controls.constant?.props.format}\n icon={\n currentSource\n ? getSourceIcon({\n source: currentSource,\n format:\n currentSource === 'Constant' ? controls.constant?.props.format : undefined\n })\n : undefined\n }\n menuItems={sources.map(config => {\n const type = config.type;\n\n return {\n id: type,\n primary: sourceLabels[config.type],\n secondary: [sourceDescriptions[type]],\n visual: (\n <Icon\n name={getSourceIcon({\n source: type,\n format: type === 'Constant' ? constantFormat : undefined\n })}\n set='streamline'\n />\n ),\n selected: config.selected\n };\n })}\n onSourceChange={onSourceChange}\n aria-describedby={`${inputUid}-selected-source`}\n />\n )}\n </>\n {control}\n </StyledDynamicInput>\n </FormField>\n\n <VisuallyHiddenText id={`${inputUid}-selected-source`}>\n {currentSource ? t('selected_noun', [sourceLabels[currentSource]]) : ''}\n </VisuallyHiddenText>\n </ThemeOverride>\n );\n}) as <\n T extends object = object,\n ConstantProps extends ConstantComponentProps<T> = ConstantComponentProps<T>,\n RuleProps extends object = object,\n FieldReferenceProps extends object = object,\n ExpressionProps extends object = object\n>(\n props: DynamicInputProps<T, ConstantProps, RuleProps, FieldReferenceProps, ExpressionProps>\n) => JSX.Element | null;\n\nexport default withTestIds(DynamicInput, getDynamicInputTestIds);\n"]}
1
+ {"version":3,"file":"DynamicInput.js","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.tsx"],"names":[],"mappings":";AAAA,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AE;oCAC9B,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC;oCAEzB,OAAO;wCACL,EAAE,EAAE,IAAI;wCACR,OAAO,EAAE,YAAY,CAAC,MAAM,CAAC,IAAI,CAAC;wCAClC,SAAS,EAAE,CAAC,kBAAkB,CAAC,IAAI,CAAC,CAAC;wCACrC,MAAM,EAAE,CACN,KAAC,IAAI,IACH,IAAI,EAAE,aAAa,CAAC;gDAClB,MAAM,EAAE,IAAI;gDACZ,MAAM,EAAE,IAAI,KAAK,UAAU,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,SAAS;6CACzD,CAAC,EACF,GAAG,EAAC,YAAY,GAChB,CACH;wCACD,QAAQ,EAAE,MAAM,CAAC,QAAQ;qCAC1B,CAAC;gCACJ,CAAC,CAAC,EACF,cAAc,EAAE,cAAc,sBACZ,GAAG,QAAQ,kBAAkB,EAC/C,QAAQ,EAAE,QAAQ,IAAI,QAAQ,GAC9B,CACH,GACA,EACF,OAAO,IACW,GACX,EAEZ,KAAC,kBAAkB,IAAC,EAAE,EAAE,GAAG,QAAQ,kBAAkB,YAClD,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,eAAe,EAAE,CAAC,YAAY,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,GACpD,IACP,CACjB,CAAC;AACJ,CAAC,CAQsB,CAAC;AAExB,eAAe,WAAW,CAAC,YAAY,EAAE,sBAAsB,CAAC,CAAC","sourcesContent":["import { forwardRef } from 'react';\nimport type { PropsWithoutRef } from 'react';\n\nimport {\n ThemeOverride,\n useI18n,\n useTestIds,\n useUID,\n Icon,\n VisuallyHiddenText,\n FormField,\n withTestIds\n} from '@pega/cosmos-react-core';\n\nimport type { ConstantComponentProps, DynamicInputProps, Source } from './DynamicInput.types';\nimport { StyledExpressionControl, StyledDynamicInput } from './DynamicInput.styles';\nimport SourceButton from './SourceButton';\nimport { getCurrentSource, getSourceIcon } from './utils';\nimport { getDynamicInputTestIds } from './DynamicInput.test-ids';\n\nconst DynamicInput = forwardRef(function DynamicInput<\n T extends object,\n ConstantProps extends ConstantComponentProps<T> = ConstantComponentProps<T>,\n RuleProps extends object = object,\n FieldReferenceProps extends object = object,\n ExpressionProps extends object = object\n>(\n {\n testId,\n label: labelProp,\n sources,\n onSourceChange,\n controls,\n required,\n hideSourceButton,\n disabled,\n readOnly,\n ...restProps\n }: PropsWithoutRef<\n DynamicInputProps<T, ConstantProps, RuleProps, FieldReferenceProps, ExpressionProps>\n >,\n ref: DynamicInputProps<T, ConstantProps, RuleProps, FieldReferenceProps, ExpressionProps>['ref']\n) {\n const testIds = useTestIds(testId, getDynamicInputTestIds);\n const inputUid = useUID();\n const t = useI18n();\n\n const label = labelProp ?? t('value');\n const currentSource = getCurrentSource(sources);\n const constantFormat = controls.constant?.props.format;\n const sourceLabels: { [key in Source]: string } = {\n Constant: t('constant_label', [\n constantFormat ? t(`dynamicInput_format_${constantFormat}`) : ''\n ]),\n Expression: t('expression_label'),\n FieldReference: t('field_reference_label'),\n Rule: t('rule_label')\n };\n const sourceDescriptions: { [key in Source]: string } = {\n Constant: t('constant_description'),\n Expression: t('expression_description'),\n FieldReference: t('field_reference_description'),\n Rule: t('rule_description')\n };\n\n let control: JSX.Element = <>{null}</>;\n\n if (currentSource === 'Constant' && controls.constant) {\n const { props, component: Component } = controls.constant;\n control = (\n <Component {...props} id={inputUid} data-testid={testIds.control} required={required} />\n );\n } else if (currentSource === 'Rule' && controls.rule) {\n const { props, component: Component } = controls.rule;\n control = (\n <Component {...props} id={inputUid} data-testid={testIds.control} required={required} />\n );\n } else if (currentSource === 'Expression' && controls.expression) {\n const { props, component: Component } = controls.expression;\n\n control = (\n <StyledExpressionControl container>\n <Component {...props} id={inputUid} data-testid={testIds.control} required={required} />\n </StyledExpressionControl>\n );\n } else if (currentSource === 'FieldReference' && controls.fieldReference) {\n const { props, component: Component } = controls.fieldReference;\n control = (\n <Component {...props} id={inputUid} data-testid={testIds.control} required={required} />\n );\n }\n\n return (\n <ThemeOverride theme={{ base: { 'icon-set': 'streamline' } }}>\n <FormField\n label={label}\n labelFor={inputUid}\n required={required}\n {...restProps}\n ref={ref}\n testId={testIds.field}\n disabled={disabled}\n readOnly={readOnly}\n >\n <StyledDynamicInput disabled={disabled}>\n <>\n {hideSourceButton ? null : (\n <SourceButton\n testId={testIds.menu}\n sources={sources}\n constantFormat={controls.constant?.props.format}\n icon={\n currentSource\n ? getSourceIcon({\n source: currentSource,\n format:\n currentSource === 'Constant' ? controls.constant?.props.format : undefined\n })\n : undefined\n }\n menuItems={sources.map(config => {\n const type = config.type;\n\n return {\n id: type,\n primary: sourceLabels[config.type],\n secondary: [sourceDescriptions[type]],\n visual: (\n <Icon\n name={getSourceIcon({\n source: type,\n format: type === 'Constant' ? constantFormat : undefined\n })}\n set='streamline'\n />\n ),\n selected: config.selected\n };\n })}\n onSourceChange={onSourceChange}\n aria-describedby={`${inputUid}-selected-source`}\n disabled={disabled || readOnly}\n />\n )}\n </>\n {control}\n </StyledDynamicInput>\n </FormField>\n\n <VisuallyHiddenText id={`${inputUid}-selected-source`}>\n {currentSource ? t('selected_noun', [sourceLabels[currentSource]]) : ''}\n </VisuallyHiddenText>\n </ThemeOverride>\n );\n}) as <\n T extends object = object,\n ConstantProps extends ConstantComponentProps<T> = ConstantComponentProps<T>,\n RuleProps extends object = object,\n FieldReferenceProps extends object = object,\n ExpressionProps extends object = object\n>(\n props: DynamicInputProps<T, ConstantProps, RuleProps, FieldReferenceProps, ExpressionProps>\n) => JSX.Element | null;\n\nexport default withTestIds(DynamicInput, getDynamicInputTestIds);\n"]}
@@ -1,3 +1,5 @@
1
1
  export declare const StyledExpressionControl: import("styled-components").StyledComponent<import("@pega/cosmos-react-core").ForwardRefForwardPropsComponent<import("@pega/cosmos-react-core").FlexProps>, import("styled-components").DefaultTheme, {}, never>;
2
- export declare const StyledDynamicInput: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
2
+ export declare const StyledDynamicInput: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
3
+ disabled?: boolean;
4
+ }, never>;
3
5
  //# sourceMappingURL=DynamicInput.styles.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"DynamicInput.styles.d.ts","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.styles.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,uBAAuB,kNAAiB,CAAC;AAEtD,eAAO,MAAM,kBAAkB,yGAsE9B,CAAC"}
1
+ {"version":3,"file":"DynamicInput.styles.d.ts","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.styles.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,uBAAuB,kNAAiB,CAAC;AAEtD,eAAO,MAAM,kBAAkB;eAA2B,OAAO;SA6EhE,CAAC"}
@@ -55,6 +55,13 @@ export const StyledDynamicInput = styled.div(({ theme: { base: { palette: { 'for
55
55
  }
56
56
  }
57
57
 
58
+ /* disabled-opacity is already being applied on DynamicInput, so we need to unset it on MenuButton */
59
+ &[disabled] {
60
+ ${StyledMenuButton}:disabled {
61
+ opacity: 1;
62
+ }
63
+ }
64
+
58
65
  ${StyledMenuButton} + * {
59
66
  flex-grow: 1;
60
67
  z-index: 1;
@@ -1 +1 @@
1
- {"version":3,"file":"DynamicInput.styles.js","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EAAE,IAAI,EAAE,iBAAiB,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAChG,OAAO,EAAE,gBAAgB,EAAE,MAAM,8DAA8D,CAAC;AAEhG,OAAO,EAAE,oBAAoB,EAAE,eAAe,EAAE,MAAM,4CAA4C,CAAC;AACnG,OAAO,EACL,yBAAyB,EACzB,0BAA0B,EAC3B,MAAM,yCAAyC,CAAC;AAEjD,MAAM,CAAC,MAAM,uBAAuB,GAAG,MAAM,CAAC,IAAI,CAAC,CAAA,EAAE,CAAC;AAEtD,MAAM,CAAC,MAAM,kBAAkB,GAAG,MAAM,CAAC,GAAG,CAC1C,CAAC,EACC,KAAK,EAAE,EACL,IAAI,EAAE,EACJ,OAAO,EAAE,EAAE,kBAAkB,EAAE,eAAe,EAAE,EAChD,eAAe,EAAE,YAAY,EAC9B,EACD,UAAU,EAAE,EACV,cAAc,EAAE,EAAE,cAAc,EAAE,sBAAsB,EAAE,EAC3D,EACF,EACF,EAAE,EAAE;IACH,OAAO,GAAG,CAAA;;;QAGN,eAAe;;;;QAIf,0BAA0B,MAAM,yBAAyB,MAAM,UAAU;;;;QAIzE,oBAAoB;;;;QAIpB,iBAAiB;;;;;;QAMjB,uBAAuB;;;;;;;;;;0BAUL,sBAAsB;;;;;;QAMxC,gBAAgB;;;wBAGA,sBAAsB;;;;iBAI7B,eAAe;;;;;;QAMxB,gBAAgB;;;;qBAIH,YAAY,CAAC,EAAE;;KAE/B,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,kBAAkB,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\n\nimport { Flex, StyledFormControl, StyledGrid, defaultThemeProp } from '@pega/cosmos-react-core';\nimport { StyledMenuButton } from '@pega/cosmos-react-core/lib/components/MenuButton/MenuButton';\n\nimport { StyledContentWrapper, StyledInputTree } from '../ObjectSelect/InputTree/InputTree.styles';\nimport {\n StyledFieldReferenceInput,\n StyledFieldReferencePicker\n} from '../FieldReference/FieldReference.styles';\n\nexport const StyledExpressionControl = styled(Flex)``;\n\nexport const StyledDynamicInput = styled.div(\n ({\n theme: {\n base: {\n palette: { 'foreground-color': foregroundColor },\n 'content-width': contentWidth\n },\n components: {\n 'form-control': { 'border-color': formControlBorderColor }\n }\n }\n }) => {\n return css`\n display: flex;\n\n ${StyledInputTree} {\n margin-inline-start: -2.5rem;\n }\n\n ${StyledFieldReferencePicker} > ${StyledFieldReferenceInput} > ${StyledGrid} {\n padding: 0;\n }\n\n ${StyledContentWrapper} {\n padding-block-start: 0;\n }\n\n ${StyledFormControl} {\n border-start-start-radius: 0;\n border-end-start-radius: 0;\n width: 100%;\n }\n\n ${StyledExpressionControl} {\n position: relative;\n z-index: 1;\n\n .react-codemirror2 {\n min-height: 0;\n }\n\n .CodeMirror,\n .CodeMirror-wrap {\n border-color: ${formControlBorderColor};\n border-start-start-radius: 0;\n border-end-start-radius: 0;\n }\n }\n\n ${StyledMenuButton} {\n z-index: 0;\n border-inline-end: 0;\n border-color: ${formControlBorderColor};\n border-start-end-radius: 0;\n border-end-end-radius: 0;\n align-self: flex-start;\n color: ${foregroundColor};\n &:focus {\n z-index: 2;\n }\n }\n\n ${StyledMenuButton} + * {\n flex-grow: 1;\n z-index: 1;\n width: 100%;\n min-width: ${contentWidth.xs};\n }\n `;\n }\n);\n\nStyledDynamicInput.defaultProps = defaultThemeProp;\n"]}
1
+ {"version":3,"file":"DynamicInput.styles.js","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EAAE,IAAI,EAAE,iBAAiB,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAChG,OAAO,EAAE,gBAAgB,EAAE,MAAM,8DAA8D,CAAC;AAEhG,OAAO,EAAE,oBAAoB,EAAE,eAAe,EAAE,MAAM,4CAA4C,CAAC;AACnG,OAAO,EACL,yBAAyB,EACzB,0BAA0B,EAC3B,MAAM,yCAAyC,CAAC;AAEjD,MAAM,CAAC,MAAM,uBAAuB,GAAG,MAAM,CAAC,IAAI,CAAC,CAAA,EAAE,CAAC;AAEtD,MAAM,CAAC,MAAM,kBAAkB,GAAG,MAAM,CAAC,GAAG,CAC1C,CAAC,EACC,KAAK,EAAE,EACL,IAAI,EAAE,EACJ,OAAO,EAAE,EAAE,kBAAkB,EAAE,eAAe,EAAE,EAChD,eAAe,EAAE,YAAY,EAC9B,EACD,UAAU,EAAE,EACV,cAAc,EAAE,EAAE,cAAc,EAAE,sBAAsB,EAAE,EAC3D,EACF,EACF,EAAE,EAAE;IACH,OAAO,GAAG,CAAA;;;QAGN,eAAe;;;;QAIf,0BAA0B,MAAM,yBAAyB,MAAM,UAAU;;;;QAIzE,oBAAoB;;;;QAIpB,iBAAiB;;;;;;QAMjB,uBAAuB;;;;;;;;;;0BAUL,sBAAsB;;;;;;QAMxC,gBAAgB;;;wBAGA,sBAAsB;;;;iBAI7B,eAAe;;;;;;;;UAQtB,gBAAgB;;;;;QAKlB,gBAAgB;;;;qBAIH,YAAY,CAAC,EAAE;;KAE/B,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,kBAAkB,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\n\nimport { Flex, StyledFormControl, StyledGrid, defaultThemeProp } from '@pega/cosmos-react-core';\nimport { StyledMenuButton } from '@pega/cosmos-react-core/lib/components/MenuButton/MenuButton';\n\nimport { StyledContentWrapper, StyledInputTree } from '../ObjectSelect/InputTree/InputTree.styles';\nimport {\n StyledFieldReferenceInput,\n StyledFieldReferencePicker\n} from '../FieldReference/FieldReference.styles';\n\nexport const StyledExpressionControl = styled(Flex)``;\n\nexport const StyledDynamicInput = styled.div<{ disabled?: boolean }>(\n ({\n theme: {\n base: {\n palette: { 'foreground-color': foregroundColor },\n 'content-width': contentWidth\n },\n components: {\n 'form-control': { 'border-color': formControlBorderColor }\n }\n }\n }) => {\n return css`\n display: flex;\n\n ${StyledInputTree} {\n margin-inline-start: -2.5rem;\n }\n\n ${StyledFieldReferencePicker} > ${StyledFieldReferenceInput} > ${StyledGrid} {\n padding: 0;\n }\n\n ${StyledContentWrapper} {\n padding-block-start: 0;\n }\n\n ${StyledFormControl} {\n border-start-start-radius: 0;\n border-end-start-radius: 0;\n width: 100%;\n }\n\n ${StyledExpressionControl} {\n position: relative;\n z-index: 1;\n\n .react-codemirror2 {\n min-height: 0;\n }\n\n .CodeMirror,\n .CodeMirror-wrap {\n border-color: ${formControlBorderColor};\n border-start-start-radius: 0;\n border-end-start-radius: 0;\n }\n }\n\n ${StyledMenuButton} {\n z-index: 0;\n border-inline-end: 0;\n border-color: ${formControlBorderColor};\n border-start-end-radius: 0;\n border-end-end-radius: 0;\n align-self: flex-start;\n color: ${foregroundColor};\n &:focus {\n z-index: 2;\n }\n }\n\n /* disabled-opacity is already being applied on DynamicInput, so we need to unset it on MenuButton */\n &[disabled] {\n ${StyledMenuButton}:disabled {\n opacity: 1;\n }\n }\n\n ${StyledMenuButton} + * {\n flex-grow: 1;\n z-index: 1;\n width: 100%;\n min-width: ${contentWidth.xs};\n }\n `;\n }\n);\n\nStyledDynamicInput.defaultProps = defaultThemeProp;\n"]}
@@ -32,7 +32,7 @@ type ComponentConfig<P> = {
32
32
  component: ComponentType<P>;
33
33
  props: DeferInfer<P>;
34
34
  };
35
- export interface DynamicInputProps<T extends object = object, ConstantProps extends ConstantComponentProps<T> = ConstantComponentProps<T>, RuleProps extends object = object, FieldReferenceProps extends object = object, ExpressionProps extends object = object> extends TestIdProp, Pick<FormFieldProps, 'labelHidden' | 'required' | 'status' | 'id' | 'info'> {
35
+ export interface DynamicInputProps<T extends object = object, ConstantProps extends ConstantComponentProps<T> = ConstantComponentProps<T>, RuleProps extends object = object, FieldReferenceProps extends object = object, ExpressionProps extends object = object> extends TestIdProp, Pick<FormFieldProps, 'labelHidden' | 'required' | 'status' | 'id' | 'info' | 'disabled' | 'readOnly'> {
36
36
  /**
37
37
  * The accessible and visual field label.
38
38
  * When used as an independent control label should represent the data field.
@@ -1 +1 @@
1
- {"version":3,"file":"DynamicInput.types.d.ts","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,GAAG,EAAE,M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AAY,CAAC;IAEtB;;OAEG;IACH,cAAc,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAEzC;;OAEG;IACH,GAAG,CAAC,EAAE,GAAG,CAAC,cAAc,CAAC,CAAC;IAE1B;;OAEG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B"}
1
+ {"version":3,"file":"DynamicInput.types.d.ts","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAEhD,OAAO,KAAK,EACV,cAAc,EACd,UAAU,EACV,aAAa,EACb,kBAAkB,EAClB,gBAAgB,EAChB,eAAe,EACf,kBAAkB,EAClB,cAAc,EACd,cAAc,EACd,UAAU,EACV,UAAU,EACV,gBAAgB,EAChB,UAAU,EACX,MAAM,yBAAyB,CAAC;AAEjC,MAAM,MAAM,kBAAkB,GAAG,UAAU,CAAC;AAC5C,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC;AACpC,MAAM,MAAM,wBAAwB,GAAG,gBAAgB,CAAC;AACxD,MAAM,MAAM,oBAAoB,GAAG,YAAY,CAAC;AAChD,MAAM,MAAM,kBAAkB,GAAG,UAAU,CAAC;AAG5C,MAAM,MAAM,MAAM,GACd,kBAAkB,GAClB,cAAc,GACd,wBAAwB,GACxB,oBAAoB,CAAC;AAEzB,MAAM,MAAM,YAAY,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,EAAE,CAAC;AAElE,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,EAAE,UAAU,CAAC,OAAO,CAAC,CAAC;IAC1B,kBAAkB,EAAE,aAAa,CAAC,OAAO,CAAC,CAAC;IAC3C,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,kBAAkB,CAAC,OAAO,CAAC,CAAC;IACtC,UAAU,EAAE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GAAG,UAAU,GAAG,UAAU,CAChF;IACH;;;;;OAKG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,QAAQ,EAAE;QACR,QAAQ,CAAC,EAAE,eAAe,CAAC,aAAa,CAAC,CAAC;QAC1C,IAAI,CAAC,EAAE,eAAe,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,CAAC,EAAE,eAAe,CAAC,mBAAmB,CAAC,CAAC;QACtD,UAAU,CAAC,EAAE,eAAe,CAAC,eAAe,CAAC,CAAC;KAC/C,CAAC;IAEF;;OAEG;IACH,OAAO,EAAE,YAAY,CAAC;IAEtB;;OAEG;IACH,cAAc,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAEzC;;OAEG;IACH,GAAG,CAAC,EAAE,GAAG,CAAC,cAAc,CAAC,CAAC;IAE1B;;OAEG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B"}
@@ -1 +1 @@
1
- {"version":3,"file":"DynamicInput.types.js","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ComponentType, Ref } from 'react';\n\nimport type {\n FormFieldProps,\n InputProps,\n TextAreaProps,\n CurrencyInputProps,\n NumberInputProps,\n PhoneInputProps,\n DateTimeInputProps,\n DateInputProps,\n TimeInputProps,\n TestIdProp,\n OmitStrict,\n FormControlProps,\n DeferInfer\n} from '@pega/cosmos-react-core';\n\nexport type ConstantSourceType = 'Constant';\nexport type RuleSourceType = 'Rule';\nexport type FieldReferenceSourceType = 'FieldReference';\nexport type ExpressionSourceType = 'Expression';\nexport type VariableSourceType = 'Variable';\n\n// Input type options\nexport type Source =\n | ConstantSourceType\n | RuleSourceType\n | FieldReferenceSourceType\n | ExpressionSourceType;\n\nexport type SourceConfig = { type: Source; selected?: boolean }[];\n\nexport type ConstantValueTypeMap = {\n Text: InputProps['value'];\n 'Text (paragraph)': TextAreaProps['value'];\n Boolean: boolean;\n Currency: CurrencyInputProps['value'];\n Percentage: NumberInputProps['value'];\n Integer: NumberInputProps['value'];\n Decimal: NumberInputProps['value'];\n Phone: PhoneInputProps['value'];\n DateTime: DateTimeInputProps['value'];\n Date: DateInputProps['value'];\n Time: TimeInputProps['value'];\n};\n\nexport type ConstantFormat = keyof ConstantValueTypeMap;\n\nexport type FormControlPropsToOmit = Pick<\n FormControlProps,\n | 'label'\n | 'labelHidden'\n | 'additionalInfo'\n | 'info'\n | 'required'\n | 'status'\n | 'readOnly'\n | 'disabled'\n | 'value'\n | 'defaultValue'\n>;\n\nexport type ConstantComponentProps<T> = OmitStrict<\n FormControlProps,\n keyof FormControlPropsToOmit\n> & {\n format?: ConstantFormat;\n} & T;\n\ntype ComponentConfig<P> = {\n component: ComponentType<P>;\n props: DeferInfer<P>;\n};\n\n// ## (DynamicInput) Top level props for the component.\nexport interface DynamicInputProps<\n T extends object = object,\n ConstantProps extends ConstantComponentProps<T> = ConstantComponentProps<T>,\n RuleProps extends object = object,\n FieldReferenceProps extends object = object,\n ExpressionProps extends object = object\n> extends TestIdProp,\n Pick<FormFieldProps, 'labelHidden' | 'required' | 'status' | 'id' | 'info'> {\n /**\n * The accessible and visual field label.\n * When used as an independent control label should represent the data field.\n * When used in combination with another LHS element the default \"Value\" may be sufficient.\n * @default \"Value\"\n */\n label?: string;\n\n /**\n * The form control displayed on the RHS\n */\n controls: {\n constant?: ComponentConfig<ConstantProps>;\n rule?: ComponentConfig<RuleProps>;\n fieldReference?: ComponentConfig<FieldReferenceProps>;\n expression?: ComponentConfig<ExpressionProps>;\n };\n\n /**\n * Methods to source a value from.\n */\n sources: SourceConfig;\n\n /**\n * Called when the source method changes.\n */\n onSourceChange: (source: Source) => void;\n\n /**\n * Ref to the component's root element.\n */\n ref?: Ref<HTMLDivElement>;\n\n /**\n * Hides source button.\n */\n hideSourceButton?: boolean;\n}\n"]}
1
+ {"version":3,"file":"DynamicInput.types.js","sourceRoot":"","sources":["../../../src/components/DynamicInput/DynamicInput.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ComponentType, Ref } from 'react';\n\nimport type {\n FormFieldProps,\n InputProps,\n TextAreaProps,\n CurrencyInputProps,\n NumberInputProps,\n PhoneInputProps,\n DateTimeInputProps,\n DateInputProps,\n TimeInputProps,\n TestIdProp,\n OmitStrict,\n FormControlProps,\n DeferInfer\n} from '@pega/cosmos-react-core';\n\nexport type ConstantSourceType = 'Constant';\nexport type RuleSourceType = 'Rule';\nexport type FieldReferenceSourceType = 'FieldReference';\nexport type ExpressionSourceType = 'Expression';\nexport type VariableSourceType = 'Variable';\n\n// Input type options\nexport type Source =\n | ConstantSourceType\n | RuleSourceType\n | FieldReferenceSourceType\n | ExpressionSourceType;\n\nexport type SourceConfig = { type: Source; selected?: boolean }[];\n\nexport type ConstantValueTypeMap = {\n Text: InputProps['value'];\n 'Text (paragraph)': TextAreaProps['value'];\n Boolean: boolean;\n Currency: CurrencyInputProps['value'];\n Percentage: NumberInputProps['value'];\n Integer: NumberInputProps['value'];\n Decimal: NumberInputProps['value'];\n Phone: PhoneInputProps['value'];\n DateTime: DateTimeInputProps['value'];\n Date: DateInputProps['value'];\n Time: TimeInputProps['value'];\n};\n\nexport type ConstantFormat = keyof ConstantValueTypeMap;\n\nexport type FormControlPropsToOmit = Pick<\n FormControlProps,\n | 'label'\n | 'labelHidden'\n | 'additionalInfo'\n | 'info'\n | 'required'\n | 'status'\n | 'readOnly'\n | 'disabled'\n | 'value'\n | 'defaultValue'\n>;\n\nexport type ConstantComponentProps<T> = OmitStrict<\n FormControlProps,\n keyof FormControlPropsToOmit\n> & {\n format?: ConstantFormat;\n} & T;\n\ntype ComponentConfig<P> = {\n component: ComponentType<P>;\n props: DeferInfer<P>;\n};\n\n// ## (DynamicInput) Top level props for the component.\nexport interface DynamicInputProps<\n T extends object = object,\n ConstantProps extends ConstantComponentProps<T> = ConstantComponentProps<T>,\n RuleProps extends object = object,\n FieldReferenceProps extends object = object,\n ExpressionProps extends object = object\n> extends TestIdProp,\n Pick<\n FormFieldProps,\n 'labelHidden' | 'required' | 'status' | 'id' | 'info' | 'disabled' | 'readOnly'\n > {\n /**\n * The accessible and visual field label.\n * When used as an independent control label should represent the data field.\n * When used in combination with another LHS element the default \"Value\" may be sufficient.\n * @default \"Value\"\n */\n label?: string;\n\n /**\n * The form control displayed on the RHS\n */\n controls: {\n constant?: ComponentConfig<ConstantProps>;\n rule?: ComponentConfig<RuleProps>;\n fieldReference?: ComponentConfig<FieldReferenceProps>;\n expression?: ComponentConfig<ExpressionProps>;\n };\n\n /**\n * Methods to source a value from.\n */\n sources: SourceConfig;\n\n /**\n * Called when the source method changes.\n */\n onSourceChange: (source: Source) => void;\n\n /**\n * Ref to the component's root element.\n */\n ref?: Ref<HTMLDivElement>;\n\n /**\n * Hides source button.\n */\n hideSourceButton?: boolean;\n}\n"]}
@@ -1,7 +1,7 @@
1
1
  import type { FC } from 'react';
2
2
  import { type MenuButtonProps, type TestIdProp, type MenuProps } from '@pega/cosmos-react-core';
3
3
  import type { ConstantFormat, DynamicInputProps } from './DynamicInput.types';
4
- interface SourceButtonProps extends Pick<DynamicInputProps, 'sources' | 'onSourceChange'>, TestIdProp {
4
+ interface SourceButtonProps extends Pick<DynamicInputProps, 'sources' | 'onSourceChange' | 'disabled'>, TestIdProp {
5
5
  /** Source menu items. */
6
6
  menuItems: MenuProps['items'];
7
7
  /** The name of the icon for the selected source. */
@@ -1 +1 @@
1
- {"version":3,"file":"SourceButton.d.ts","sourceRoot":"","sources":["../../../src/components/DynamicInput/SourceButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAEhC,OAAO,EAGL,KAAK,eAAe,EACpB,KAAK,UAAU,EACf,KAAK,SAAS,EACf,MAAM,yBAAyB,CAAC;AAEjC,OAAO,KAAK,EAAE,cAAc,EAAE,iBAAiB,EAAU,MAAM,sBAAsB,CAAC;AAEtF,UAAU,iBACR,SAAQ,IAAI,CAAC,iBAAiB,EAAE,SAAS,GAAG,gBAAgB,CAAC,EAC3D,UAAU;IACZ,yBAAyB;IACzB,SAAS,EAAE,SAAS,CAAC,OAAO,CAAC,CAAC;IAC9B,oDAAoD;IACpD,IAAI,CAAC,EAAE,eAAe,CAAC,MAAM,CAAC,CAAC;IAC/B,sCAAsC;IACtC,cAAc,CAAC,EAAE,cAAc,CAAC;CACjC;AAED,QAAA,MAAM,YAAY,EAAE,EAAE,CAAC,iBAAiB,CA6BvC,CAAC;AAEF,eAAe,YAAY,CAAC"}
1
+ {"version":3,"file":"SourceButton.d.ts","sourceRoot":"","sources":["../../../src/components/DynamicInput/SourceButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAEhC,OAAO,EAGL,KAAK,eAAe,EACpB,KAAK,UAAU,EACf,KAAK,SAAS,EACf,MAAM,yBAAyB,CAAC;AAEjC,OAAO,KAAK,EAAE,cAAc,EAAE,iBAAiB,EAAU,MAAM,sBAAsB,CAAC;AAEtF,UAAU,iBACR,SAAQ,IAAI,CAAC,iBAAiB,EAAE,SAAS,GAAG,gBAAgB,GAAG,UAAU,CAAC,EACxE,UAAU;IACZ,yBAAyB;IACzB,SAAS,EAAE,SAAS,CAAC,OAAO,CAAC,CAAC;IAC9B,oDAAoD;IACpD,IAAI,CAAC,EAAE,eAAe,CAAC,MAAM,CAAC,CAAC;IAC/B,sCAAsC;IACtC,cAAc,CAAC,EAAE,cAAc,CAAC;CACjC;AAED,QAAA,MAAM,YAAY,EAAE,EAAE,CAAC,iBAAiB,CA6BvC,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"SourceButton.js","sourceRoot":"","sources":["../../../src/components/DynamicInput/SourceButton.tsx"],"names":[],"mappings":";AAEA,OAAO,EACL,UAAU,EACV,OAAO,EAIR,MAAM,yBAAyB,CAAC;AAejC,MAAM,YAAY,GAA0B,CAAC,EAC3C,OAAO,EACP,IAAI,EACJ,cAAc,EACd,cAAc,EACd,MAAM,EACN,SAAS,EACT,GAAG,SAAS,EACM,EAAE,EAAE;IACtB,MAAM,CAAC,GAAG,OAAO,EAAE,CAAC;IAEpB,OAAO,CACL,KAAC,UAAU,IACT,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,CAAC,CAAC,YAAY,CAAC,KACjB,SAAS,EACb,IAAI,EAAE,IAAI,EACV,OAAO,EAAC,YAAY,EACpB,IAAI,EAAE;YACJ,IAAI,EAAE,eAAe;YACrB,KAAK,EAAE,SAAS;YAChB,WAAW,EAAE,EAAE,CAAC,EAAE;gBAChB,cAAc,CAAC,EAAY,CAAC,CAAC;YAC/B,CAAC;SACF,EACD,SAAS,QACT,QAAQ,SACR,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["import type { FC } from 'react';\n\nimport {\n MenuButton,\n useI18n,\n type MenuButtonProps,\n type TestIdProp,\n type MenuProps\n} from '@pega/cosmos-react-core';\n\nimport type { ConstantFormat, DynamicInputProps, Source } from './DynamicInput.types';\n\ninterface SourceButtonProps\n extends Pick<DynamicInputProps, 'sources' | 'onSourceChange'>,\n TestIdProp {\n /** Source menu items. */\n menuItems: MenuProps['items'];\n /** The name of the icon for the selected source. */\n icon?: MenuButtonProps['icon'];\n /** The input format for constants. */\n constantFormat?: ConstantFormat;\n}\n\nconst SourceButton: FC<SourceButtonProps> = ({\n sources,\n icon,\n constantFormat,\n onSourceChange,\n testId,\n menuItems,\n ...restProps\n}: SourceButtonProps) => {\n const t = useI18n();\n\n return (\n <MenuButton\n testId={testId}\n text={t('value_type')}\n {...restProps}\n icon={icon}\n iconSet='streamline'\n menu={{\n mode: 'single-select',\n items: menuItems,\n onItemClick: id => {\n onSourceChange(id as Source);\n }\n }}\n showArrow\n iconOnly\n />\n );\n};\n\nexport default SourceButton;\n"]}
1
+ {"version":3,"file":"SourceButton.js","sourceRoot":"","sources":["../../../src/components/DynamicInput/SourceButton.tsx"],"names":[],"mappings":";AAEA,OAAO,EACL,UAAU,EACV,OAAO,EAIR,MAAM,yBAAyB,CAAC;AAejC,MAAM,YAAY,GAA0B,CAAC,EAC3C,OAAO,EACP,IAAI,EACJ,cAAc,EACd,cAAc,EACd,MAAM,EACN,SAAS,EACT,GAAG,SAAS,EACM,EAAE,EAAE;IACtB,MAAM,CAAC,GAAG,OAAO,EAAE,CAAC;IAEpB,OAAO,CACL,KAAC,UAAU,IACT,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,CAAC,CAAC,YAAY,CAAC,KACjB,SAAS,EACb,IAAI,EAAE,IAAI,EACV,OAAO,EAAC,YAAY,EACpB,IAAI,EAAE;YACJ,IAAI,EAAE,eAAe;YACrB,KAAK,EAAE,SAAS;YAChB,WAAW,EAAE,EAAE,CAAC,EAAE;gBAChB,cAAc,CAAC,EAAY,CAAC,CAAC;YAC/B,CAAC;SACF,EACD,SAAS,QACT,QAAQ,SACR,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["import type { FC } from 'react';\n\nimport {\n MenuButton,\n useI18n,\n type MenuButtonProps,\n type TestIdProp,\n type MenuProps\n} from '@pega/cosmos-react-core';\n\nimport type { ConstantFormat, DynamicInputProps, Source } from './DynamicInput.types';\n\ninterface SourceButtonProps\n extends Pick<DynamicInputProps, 'sources' | 'onSourceChange' | 'disabled'>,\n TestIdProp {\n /** Source menu items. */\n menuItems: MenuProps['items'];\n /** The name of the icon for the selected source. */\n icon?: MenuButtonProps['icon'];\n /** The input format for constants. */\n constantFormat?: ConstantFormat;\n}\n\nconst SourceButton: FC<SourceButtonProps> = ({\n sources,\n icon,\n constantFormat,\n onSourceChange,\n testId,\n menuItems,\n ...restProps\n}: SourceButtonProps) => {\n const t = useI18n();\n\n return (\n <MenuButton\n testId={testId}\n text={t('value_type')}\n {...restProps}\n icon={icon}\n iconSet='streamline'\n menu={{\n mode: 'single-select',\n items: menuItems,\n onItemClick: id => {\n onSourceChange(id as Source);\n }\n }}\n showArrow\n iconOnly\n />\n );\n};\n\nexport default SourceButton;\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pega/cosmos-react-build",
3
- "version": "9.0.0-build.14.0",
3
+ "version": "9.0.0-build.14.10",
4
4
  "license": "SEE LICENSE IN LICENSE",
5
5
  "author": "Pegasystems",
6
6
  "sideEffects": false,
@@ -14,9 +14,9 @@
14
14
  "build": "tsc -b tsconfig.build.json"
15
15
  },
16
16
  "dependencies": {
17
- "@pega/cosmos-react-core": "9.0.0-build.14.0",
18
- "@pega/cosmos-react-dnd": "9.0.0-build.14.0",
19
- "@pega/cosmos-react-rte": "9.0.0-build.14.0",
17
+ "@pega/cosmos-react-core": "9.0.0-build.14.10",
18
+ "@pega/cosmos-react-dnd": "9.0.0-build.14.10",
19
+ "@pega/cosmos-react-rte": "9.0.0-build.14.10",
20
20
  "@types/codemirror": "^5.60.15",
21
21
  "@types/dagre": "^0.7.46",
22
22
  "@types/react": "^17.0.62 || ^18.3.3",
@@ -37,7 +37,7 @@
37
37
  "@storybook/react": "~8.2.9",
38
38
  "@testing-library/react": "^16.0.0",
39
39
  "@testing-library/user-event": "^14.6.1",
40
- "typescript": "~5.8.3"
40
+ "typescript": "~5.9.3"
41
41
  },
42
42
  "overrides": {
43
43
  "react-codemirror2": {