@superblocksteam/library 2.0.0-next.97 → 2.0.0-next.99
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/{allPaths-C6qeZ4_p.js → allPaths-BwY_k0XB.js} +2 -2
- package/dist/{allPaths-C6qeZ4_p.js.map → allPaths-BwY_k0XB.js.map} +1 -1
- package/dist/{allPaths-Dsgw01PB.js → allPaths-D7ld9CX_.js} +2 -2
- package/dist/{allPaths-Dsgw01PB.js.map → allPaths-D7ld9CX_.js.map} +1 -1
- package/dist/{allPathsLoader-4bTX5Z5s.js → allPathsLoader-BK2ifVAz.js} +3 -3
- package/dist/{allPathsLoader-4bTX5Z5s.js.map → allPathsLoader-BK2ifVAz.js.map} +1 -1
- package/dist/{allPathsLoader-BjTp2_ti.js → allPathsLoader-BedT2t1j.js} +3 -3
- package/dist/{allPathsLoader-BjTp2_ti.js.map → allPathsLoader-BedT2t1j.js.map} +1 -1
- package/dist/{index-Cfiz5DdU.js → index-D_-27jtA.js} +180 -200
- package/dist/{index-Cfiz5DdU.js.map → index-D_-27jtA.js.map} +1 -1
- package/dist/index.js +2 -2
- package/dist/{splitPathsBySizeLoader-Ba_jngBn.js → splitPathsBySizeLoader-B2GV93jI.js} +2 -2
- package/dist/{splitPathsBySizeLoader-Ba_jngBn.js.map → splitPathsBySizeLoader-B2GV93jI.js.map} +1 -1
- package/dist/{splitPathsBySizeLoader-BHujcI7q.js → splitPathsBySizeLoader-C5SxMHH4.js} +2 -2
- package/dist/{splitPathsBySizeLoader-BHujcI7q.js.map → splitPathsBySizeLoader-C5SxMHH4.js.map} +1 -1
- package/dist-types/internal-testing/components/form.d.ts +1 -0
- package/dist-types/lib/user-facing/components/date-picker/index.d.ts +4 -0
- package/dist-types/lib/user-facing/components/date-picker/props.d.ts +4 -0
- package/dist-types/lib/user-facing/components/date-picker/types.d.ts +3 -0
- package/dist-types/lib/user-facing/components/dropdown/dropdown-component.d.ts +1 -1
- package/dist-types/lib/user-facing/components/dropdown/props.d.ts +2 -3
- package/dist-types/lib/user-facing/components/input/index.d.ts +6 -6
- package/dist-types/lib/user-facing/components/input/props.d.ts +6 -6
- package/dist-types/lib/user-facing/components/text/index.d.ts +6 -6
- package/dist-types/lib/user-facing/components/text/props.d.ts +13 -12
- package/dist-types/lib/user-facing/components/text/utils.d.ts +1 -1
- package/dist-types/lib/user-facing/properties-panel/mixins/appearance-properties.d.ts +1 -0
- package/dist-types/lib/user-facing/properties-panel/mixins/form-inputs-properties.d.ts +2 -2
- package/dist-types/lib/user-facing/themes/constants.d.ts +2 -2
- package/package.json +2 -2
|
@@ -1078,11 +1078,6 @@ intentClass$1(Intent$1.SUCCESS);
|
|
|
1078
1078
|
intentClass$1(Intent$1.WARNING);
|
|
1079
1079
|
intentClass$1(Intent$1.DANGER);
|
|
1080
1080
|
var TEXT_OVERFLOW_ELLIPSIS$1 = "".concat(NS$6, "-text-overflow-ellipsis");
|
|
1081
|
-
var BLOCKQUOTE = "".concat(NS$6, "-blockquote");
|
|
1082
|
-
var CODE = "".concat(NS$6, "-code");
|
|
1083
|
-
var CODE_BLOCK = "".concat(NS$6, "-code-block");
|
|
1084
|
-
var HEADING = "".concat(NS$6, "-heading");
|
|
1085
|
-
var LIST = "".concat(NS$6, "-list");
|
|
1086
1081
|
var BUTTON$1 = "".concat(NS$6, "-button");
|
|
1087
1082
|
var BUTTON_GROUP = "".concat(BUTTON$1, "-group");
|
|
1088
1083
|
var BUTTON_SPINNER$1 = "".concat(BUTTON$1, "-spinner");
|
|
@@ -1096,7 +1091,6 @@ var INPUT_GROUP$1 = "".concat(INPUT$1, "-group");
|
|
|
1096
1091
|
var INPUT_LEFT_CONTAINER$1 = "".concat(INPUT$1, "-left-container");
|
|
1097
1092
|
var INPUT_ACTION$1 = "".concat(INPUT$1, "-action");
|
|
1098
1093
|
var RESIZABLE_INPUT_SPAN = "".concat(NS$6, "-resizable-input-span");
|
|
1099
|
-
var LABEL = "".concat(NS$6, "-label");
|
|
1100
1094
|
var MENU$1 = "".concat(NS$6, "-menu");
|
|
1101
1095
|
var MENU_ITEM$1 = "".concat(MENU$1, "-item");
|
|
1102
1096
|
var MENU_ITEM_IS_SELECTABLE$1 = "".concat(MENU_ITEM$1, "-is-selectable");
|
|
@@ -2690,14 +2684,14 @@ function getLoaderFn$1(options) {
|
|
|
2690
2684
|
if (!(loader === "all")) return [3, 3];
|
|
2691
2685
|
return [4, import(
|
|
2692
2686
|
/* webpackChunkName: "blueprint-icons-all-paths-loader" */
|
|
2693
|
-
"./allPathsLoader-
|
|
2687
|
+
"./allPathsLoader-BedT2t1j.js"
|
|
2694
2688
|
)];
|
|
2695
2689
|
case 2:
|
|
2696
2690
|
return [2, _b2.sent().allPathsLoader];
|
|
2697
2691
|
case 3:
|
|
2698
2692
|
return [4, import(
|
|
2699
2693
|
/* webpackChunkName: "blueprint-icons-split-paths-by-size-loader" */
|
|
2700
|
-
"./splitPathsBySizeLoader-
|
|
2694
|
+
"./splitPathsBySizeLoader-C5SxMHH4.js"
|
|
2701
2695
|
)];
|
|
2702
2696
|
case 4:
|
|
2703
2697
|
return [2, _b2.sent().splitPathsBySizeLoader];
|
|
@@ -3184,24 +3178,6 @@ function renderButtonContents$1(props2) {
|
|
|
3184
3178
|
React.createElement(Icon$3, { key: "rightIcon", icon: rightIcon })
|
|
3185
3179
|
);
|
|
3186
3180
|
}
|
|
3187
|
-
function htmlElement(tagName, tagClassName) {
|
|
3188
|
-
return React.forwardRef(function(props2, ref2) {
|
|
3189
|
-
var className = props2.className, children = props2.children, htmlProps = __rest$B(props2, ["className", "children"]);
|
|
3190
|
-
return React.createElement(tagName, __assign$2(__assign$2({}, htmlProps), { className: classNames(tagClassName, className), ref: ref2 }), children);
|
|
3191
|
-
});
|
|
3192
|
-
}
|
|
3193
|
-
htmlElement("h1", HEADING);
|
|
3194
|
-
htmlElement("h2", HEADING);
|
|
3195
|
-
htmlElement("h3", HEADING);
|
|
3196
|
-
htmlElement("h4", HEADING);
|
|
3197
|
-
htmlElement("h5", HEADING);
|
|
3198
|
-
htmlElement("h6", HEADING);
|
|
3199
|
-
htmlElement("blockquote", BLOCKQUOTE);
|
|
3200
|
-
htmlElement("code", CODE);
|
|
3201
|
-
htmlElement("pre", CODE_BLOCK);
|
|
3202
|
-
var Label = htmlElement("label", LABEL);
|
|
3203
|
-
htmlElement("ol", LIST);
|
|
3204
|
-
htmlElement("ul", LIST);
|
|
3205
3181
|
function _extends$5() {
|
|
3206
3182
|
return _extends$5 = Object.assign ? Object.assign.bind() : function(n2) {
|
|
3207
3183
|
for (var e3 = 1; e3 < arguments.length; e3++) {
|
|
@@ -48906,18 +48882,13 @@ const BUTTON_PADDING = {
|
|
|
48906
48882
|
top: { mode: "px", value: 9 },
|
|
48907
48883
|
bottom: { mode: "px", value: 9 }
|
|
48908
48884
|
};
|
|
48909
|
-
const DROPDOWN_PADDING = {
|
|
48910
|
-
left: Dim.px(10),
|
|
48911
|
-
right: Dim.px(10),
|
|
48912
|
-
top: Dim.px(4),
|
|
48913
|
-
bottom: Dim.px(4)
|
|
48914
|
-
};
|
|
48915
48885
|
const INPUT_PADDING = {
|
|
48916
48886
|
left: Dim.px(10),
|
|
48917
48887
|
right: Dim.px(10),
|
|
48918
48888
|
top: Dim.px(8),
|
|
48919
48889
|
bottom: Dim.px(8)
|
|
48920
48890
|
};
|
|
48891
|
+
const DROPDOWN_PADDING = INPUT_PADDING;
|
|
48921
48892
|
const KEY_VALUE_PADDING = {
|
|
48922
48893
|
left: Dim.px(20),
|
|
48923
48894
|
right: Dim.px(20),
|
|
@@ -118269,6 +118240,16 @@ const labelTextStyle = () => textStyleProp({
|
|
|
118269
118240
|
}
|
|
118270
118241
|
}).default(() => ({
|
|
118271
118242
|
variant: DEFAULT_INPUT_WIDGET_LABEL_STYLE_VARIANT,
|
|
118243
|
+
textColor: {
|
|
118244
|
+
default: Theme.colors.neutral700
|
|
118245
|
+
}
|
|
118246
|
+
}));
|
|
118247
|
+
const inputTextStyle = () => textStyleProp({
|
|
118248
|
+
propertiesPanel: {
|
|
118249
|
+
label: "Input style"
|
|
118250
|
+
}
|
|
118251
|
+
}).default(() => ({
|
|
118252
|
+
variant: DEFAULT_INPUT_WIDGET_INPUT_STYLE_VARIANT,
|
|
118272
118253
|
textColor: {
|
|
118273
118254
|
default: Theme.colors.neutral900
|
|
118274
118255
|
}
|
|
@@ -118349,7 +118330,7 @@ function getDefaultBorderRadius() {
|
|
|
118349
118330
|
}
|
|
118350
118331
|
return createBorderRadiusObject(borderRadius2);
|
|
118351
118332
|
}
|
|
118352
|
-
const textStyle$
|
|
118333
|
+
const textStyle$1 = textStyleProp().default(function() {
|
|
118353
118334
|
return {
|
|
118354
118335
|
variant: "buttonLabel",
|
|
118355
118336
|
textColor: {
|
|
@@ -118403,7 +118384,7 @@ const propertiesDefinition$h = {
|
|
|
118403
118384
|
return !!this.icon;
|
|
118404
118385
|
}
|
|
118405
118386
|
}),
|
|
118406
|
-
textStyle: textStyle$
|
|
118387
|
+
textStyle: textStyle$1,
|
|
118407
118388
|
backgroundColor: colorProp({
|
|
118408
118389
|
label: "Background color",
|
|
118409
118390
|
visibility: "SHOW_NAME",
|
|
@@ -125221,7 +125202,7 @@ const getIconPadding = (paddingValue = INPUT_PADDING.right, iconSize = DEFAULT_I
|
|
|
125221
125202
|
const DEFAULT_LABEL_WIDTH_IN_PERCENT = 30;
|
|
125222
125203
|
const DEFAULT_LABEL_WIDTH_IN_PX = 80;
|
|
125223
125204
|
const WIDGET_PADDING = 1;
|
|
125224
|
-
const labelStyleRaw
|
|
125205
|
+
const labelStyleRaw = {
|
|
125225
125206
|
vertical: `
|
|
125226
125207
|
margin: var(--label-margin) var(--label-margin) var(--label-margin) 0;
|
|
125227
125208
|
`,
|
|
@@ -125231,10 +125212,10 @@ const labelStyleRaw$1 = {
|
|
|
125231
125212
|
};
|
|
125232
125213
|
const labelStyle = {
|
|
125233
125214
|
vertical: Ae$1`
|
|
125234
|
-
${labelStyleRaw
|
|
125215
|
+
${labelStyleRaw.vertical}
|
|
125235
125216
|
`,
|
|
125236
125217
|
horizontal: Ae$1`
|
|
125237
|
-
${labelStyleRaw
|
|
125218
|
+
${labelStyleRaw.horizontal}
|
|
125238
125219
|
`
|
|
125239
125220
|
};
|
|
125240
125221
|
const getLabelWidthCssValue = (dimension) => {
|
|
@@ -125685,7 +125666,7 @@ const ControlGroupClassName = styleAsClass`
|
|
|
125685
125666
|
&[data-vertical="true"] {
|
|
125686
125667
|
&&&& {
|
|
125687
125668
|
label {
|
|
125688
|
-
${labelStyleRaw
|
|
125669
|
+
${labelStyleRaw.vertical}
|
|
125689
125670
|
flex: 0 0 auto;
|
|
125690
125671
|
max-width: 100%;
|
|
125691
125672
|
}
|
|
@@ -125702,7 +125683,7 @@ const ControlGroupClassName = styleAsClass`
|
|
|
125702
125683
|
align-items: baseline;
|
|
125703
125684
|
|
|
125704
125685
|
label {
|
|
125705
|
-
${labelStyleRaw
|
|
125686
|
+
${labelStyleRaw.horizontal}
|
|
125706
125687
|
text-align: left;
|
|
125707
125688
|
align-self: flex-start;
|
|
125708
125689
|
|
|
@@ -126469,7 +126450,7 @@ const _InputComponent = class _InputComponent extends React__default.Component {
|
|
|
126469
126450
|
"data-disabled": this.props.isDisabled,
|
|
126470
126451
|
children: [
|
|
126471
126452
|
this.props.label ? /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
126472
|
-
|
|
126453
|
+
"label",
|
|
126473
126454
|
{
|
|
126474
126455
|
className: `${CLASS_NAMES.ELLIPSIS_TEXT} ${this.props.isLoading ? SKELETON : ""} ${this.props.labelClassName ?? CLASS_NAMES.INPUT_LABEL} ${this.props.isDisabled ? CLASS_NAMES.DISABLED_MODIFIER : ""}
|
|
126475
126456
|
`,
|
|
@@ -126767,7 +126748,7 @@ const getCustomValidationProperties = ({
|
|
|
126767
126748
|
const getFractionDigitsProperties = ({
|
|
126768
126749
|
schema
|
|
126769
126750
|
} = {}) => ({
|
|
126770
|
-
|
|
126751
|
+
minDecimals: Prop.number().readAndWrite().propertiesPanel({
|
|
126771
126752
|
label: "Min decimals",
|
|
126772
126753
|
helpText: "The minimum number of digits after the decimal separator",
|
|
126773
126754
|
controlType: "INPUT_TEXT",
|
|
@@ -126776,7 +126757,7 @@ const getFractionDigitsProperties = ({
|
|
|
126776
126757
|
visibility: "SHOW_NAME",
|
|
126777
126758
|
defaultOnAdd: () => 1
|
|
126778
126759
|
}),
|
|
126779
|
-
|
|
126760
|
+
maxDecimals: Prop.number().readAndWrite().propertiesPanel({
|
|
126780
126761
|
label: "Max decimals",
|
|
126781
126762
|
helpText: "The maximum number of digits after the decimal separator",
|
|
126782
126763
|
controlType: "INPUT_TEXT",
|
|
@@ -126839,16 +126820,6 @@ const textLengthProps = {
|
|
|
126839
126820
|
isRemovable: true
|
|
126840
126821
|
})
|
|
126841
126822
|
};
|
|
126842
|
-
const textStyle$2 = textStyleProp({
|
|
126843
|
-
propertiesPanel: {
|
|
126844
|
-
label: "Input text style"
|
|
126845
|
-
}
|
|
126846
|
-
}).default(() => ({
|
|
126847
|
-
variant: DEFAULT_INPUT_WIDGET_INPUT_STYLE_VARIANT,
|
|
126848
|
-
textColor: {
|
|
126849
|
-
default: Theme.colors.neutral900
|
|
126850
|
-
}
|
|
126851
|
-
}));
|
|
126852
126823
|
const propertiesDefinition$d = {
|
|
126853
126824
|
general: Section.category(PropsPanelCategory.Content).children({
|
|
126854
126825
|
label: Prop.string().readAndWrite().default("").propertiesPanel({
|
|
@@ -126873,7 +126844,7 @@ const propertiesDefinition$d = {
|
|
|
126873
126844
|
variants: [
|
|
126874
126845
|
{
|
|
126875
126846
|
inputType: Prop.literal(InputTypes.NUMBER),
|
|
126876
|
-
|
|
126847
|
+
numberFormat: Prop.string().readAndWrite().default("standard").propertiesPanel({
|
|
126877
126848
|
label: "Number format",
|
|
126878
126849
|
controlType: "DROP_DOWN",
|
|
126879
126850
|
options: NUMBER_FORMATTING_OPTIONS,
|
|
@@ -126882,7 +126853,7 @@ const propertiesDefinition$d = {
|
|
|
126882
126853
|
},
|
|
126883
126854
|
{
|
|
126884
126855
|
inputType: Prop.literal(InputTypes.CURRENCY),
|
|
126885
|
-
|
|
126856
|
+
numberFormat: Prop.string().readAndWrite().default("standard").propertiesPanel({
|
|
126886
126857
|
label: "Number format",
|
|
126887
126858
|
controlType: "DROP_DOWN",
|
|
126888
126859
|
options: NUMBER_FORMATTING_OPTIONS,
|
|
@@ -126925,7 +126896,7 @@ const propertiesDefinition$d = {
|
|
|
126925
126896
|
controlType: "INPUT_TEXT",
|
|
126926
126897
|
placeholder: "Input text"
|
|
126927
126898
|
}),
|
|
126928
|
-
textStyle:
|
|
126899
|
+
textStyle: inputTextStyle(),
|
|
126929
126900
|
backgroundColor: colorProp({
|
|
126930
126901
|
label: "Background",
|
|
126931
126902
|
helpText: "Changes the color of the background"
|
|
@@ -127074,7 +127045,9 @@ const SbInput = registerSbComponent(
|
|
|
127074
127045
|
padding: padding2,
|
|
127075
127046
|
currency,
|
|
127076
127047
|
currencyCodeDisplay,
|
|
127077
|
-
|
|
127048
|
+
numberFormat,
|
|
127049
|
+
minDecimals,
|
|
127050
|
+
maxDecimals,
|
|
127078
127051
|
labelPosition: labelPosition2,
|
|
127079
127052
|
label,
|
|
127080
127053
|
stepper,
|
|
@@ -127176,7 +127149,9 @@ const SbInput = registerSbComponent(
|
|
|
127176
127149
|
backgroundColor,
|
|
127177
127150
|
border: border2,
|
|
127178
127151
|
inputType,
|
|
127179
|
-
numberFormatting,
|
|
127152
|
+
numberFormatting: numberFormat,
|
|
127153
|
+
minimumFractionDigits: minDecimals,
|
|
127154
|
+
maximumFractionDigits: maxDecimals,
|
|
127180
127155
|
isDisabled,
|
|
127181
127156
|
placeholder: placeholderText,
|
|
127182
127157
|
inputClassName: inputClassNames,
|
|
@@ -133895,13 +133870,13 @@ const Button$2 = memo(
|
|
|
133895
133870
|
Button$2.displayName = "Button";
|
|
133896
133871
|
Button$2.__ANT_BUTTON = true;
|
|
133897
133872
|
const DEFAULT_TEXT_WIDGET_TEXT_STYLE_VARIANT = "label";
|
|
133898
|
-
const
|
|
133873
|
+
const numberFormatProperty = Prop.string().readAndWrite().default("standard").propertiesPanel({
|
|
133899
133874
|
label: "Number format",
|
|
133900
133875
|
controlType: "DROP_DOWN",
|
|
133901
133876
|
options: NUMBER_FORMATTING_OPTIONS,
|
|
133902
133877
|
helpText: "The display format of the number"
|
|
133903
133878
|
});
|
|
133904
|
-
const textStyle
|
|
133879
|
+
const textStyle = textStyleProp().default(function() {
|
|
133905
133880
|
return {
|
|
133906
133881
|
variant: DEFAULT_TEXT_WIDGET_TEXT_STYLE_VARIANT,
|
|
133907
133882
|
textColor: Theme.typographies.label.textColor
|
|
@@ -133926,7 +133901,7 @@ const propertiesDefinition$b = {
|
|
|
133926
133901
|
})
|
|
133927
133902
|
}),
|
|
133928
133903
|
appearance: Section.category(PropsPanelCategory.Appearance).children({
|
|
133929
|
-
textStyle
|
|
133904
|
+
textStyle,
|
|
133930
133905
|
horizontalAlign: Prop.string().readAndWrite().default("left").propertiesPanel({
|
|
133931
133906
|
label: "Horizontal align",
|
|
133932
133907
|
helpText: "The horizontal alignment of the text relative to the component width",
|
|
@@ -133945,7 +133920,10 @@ const propertiesDefinition$b = {
|
|
|
133945
133920
|
{ icon: "VERTICAL_TOP", value: "top" },
|
|
133946
133921
|
{ icon: "VERTICAL_CENTER", value: "center" },
|
|
133947
133922
|
{ icon: "VERTICAL_BOTTOM", value: "bottom" }
|
|
133948
|
-
]
|
|
133923
|
+
],
|
|
133924
|
+
isVisible: function() {
|
|
133925
|
+
return this.height.mode !== "fit";
|
|
133926
|
+
}
|
|
133949
133927
|
}),
|
|
133950
133928
|
wrapText: Prop.boolean().readAndWrite().propertiesPanel({
|
|
133951
133929
|
label: "Wrap text",
|
|
@@ -133996,12 +133974,12 @@ const propertiesDefinition$b = {
|
|
|
133996
133974
|
value: item
|
|
133997
133975
|
}))
|
|
133998
133976
|
}),
|
|
133999
|
-
|
|
133977
|
+
numberFormat: numberFormatProperty,
|
|
134000
133978
|
...getFractionDigitsProperties()
|
|
134001
133979
|
},
|
|
134002
133980
|
{
|
|
134003
133981
|
textType: Prop.literal("number"),
|
|
134004
|
-
|
|
133982
|
+
numberFormat: numberFormatProperty,
|
|
134005
133983
|
...getFractionDigitsProperties()
|
|
134006
133984
|
},
|
|
134007
133985
|
{
|
|
@@ -134063,9 +134041,9 @@ const StyledText = styleAsClass`
|
|
|
134063
134041
|
`;
|
|
134064
134042
|
const useText = ({
|
|
134065
134043
|
text,
|
|
134066
|
-
|
|
134067
|
-
|
|
134068
|
-
|
|
134044
|
+
numberFormat,
|
|
134045
|
+
minDecimals,
|
|
134046
|
+
maxDecimals,
|
|
134069
134047
|
textType,
|
|
134070
134048
|
currency,
|
|
134071
134049
|
dateInputFormat,
|
|
@@ -134074,19 +134052,14 @@ const useText = ({
|
|
|
134074
134052
|
return useMemo$2(() => {
|
|
134075
134053
|
switch (textType) {
|
|
134076
134054
|
case "number":
|
|
134077
|
-
return formatNumber(
|
|
134078
|
-
text,
|
|
134079
|
-
notation,
|
|
134080
|
-
minimumFractionDigits,
|
|
134081
|
-
maximumFractionDigits
|
|
134082
|
-
);
|
|
134055
|
+
return formatNumber(text, numberFormat, minDecimals, maxDecimals);
|
|
134083
134056
|
case "currency":
|
|
134084
134057
|
return formatCurrency(
|
|
134085
134058
|
text,
|
|
134086
134059
|
currency,
|
|
134087
|
-
|
|
134088
|
-
|
|
134089
|
-
|
|
134060
|
+
numberFormat,
|
|
134061
|
+
minDecimals,
|
|
134062
|
+
maxDecimals
|
|
134090
134063
|
);
|
|
134091
134064
|
case "date":
|
|
134092
134065
|
return formatDate(text, dateInputFormat, dateOutputFormat);
|
|
@@ -134095,9 +134068,9 @@ const useText = ({
|
|
|
134095
134068
|
}
|
|
134096
134069
|
}, [
|
|
134097
134070
|
text,
|
|
134098
|
-
|
|
134099
|
-
|
|
134100
|
-
|
|
134071
|
+
numberFormat,
|
|
134072
|
+
minDecimals,
|
|
134073
|
+
maxDecimals,
|
|
134101
134074
|
textType,
|
|
134102
134075
|
currency,
|
|
134103
134076
|
dateInputFormat,
|
|
@@ -134203,9 +134176,9 @@ const SbText = registerSbComponent(
|
|
|
134203
134176
|
name,
|
|
134204
134177
|
iconPosition,
|
|
134205
134178
|
icon,
|
|
134206
|
-
|
|
134207
|
-
|
|
134208
|
-
|
|
134179
|
+
numberFormat,
|
|
134180
|
+
minDecimals,
|
|
134181
|
+
maxDecimals,
|
|
134209
134182
|
textType,
|
|
134210
134183
|
currency,
|
|
134211
134184
|
dateInputFormat,
|
|
@@ -134229,9 +134202,9 @@ const SbText = registerSbComponent(
|
|
|
134229
134202
|
});
|
|
134230
134203
|
const formattedText = useText({
|
|
134231
134204
|
text,
|
|
134232
|
-
|
|
134233
|
-
|
|
134234
|
-
|
|
134205
|
+
numberFormat,
|
|
134206
|
+
minDecimals,
|
|
134207
|
+
maxDecimals,
|
|
134235
134208
|
textType,
|
|
134236
134209
|
currency,
|
|
134237
134210
|
dateInputFormat,
|
|
@@ -144483,14 +144456,14 @@ function getLoaderFn(options) {
|
|
|
144483
144456
|
if (!(loader === "all")) return [3, 3];
|
|
144484
144457
|
return [4, import(
|
|
144485
144458
|
/* webpackChunkName: "blueprint-icons-all-paths-loader" */
|
|
144486
|
-
"./allPathsLoader-
|
|
144459
|
+
"./allPathsLoader-BK2ifVAz.js"
|
|
144487
144460
|
)];
|
|
144488
144461
|
case 2:
|
|
144489
144462
|
return [2, _b2.sent().allPathsLoader];
|
|
144490
144463
|
case 3:
|
|
144491
144464
|
return [4, import(
|
|
144492
144465
|
/* webpackChunkName: "blueprint-icons-split-paths-by-size-loader" */
|
|
144493
|
-
"./splitPathsBySizeLoader-
|
|
144466
|
+
"./splitPathsBySizeLoader-B2GV93jI.js"
|
|
144494
144467
|
)];
|
|
144495
144468
|
case 4:
|
|
144496
144469
|
return [2, _b2.sent().splitPathsBySizeLoader];
|
|
@@ -152303,6 +152276,32 @@ const dependencies = { "date-fns": "^2.30.0" };
|
|
|
152303
152276
|
const packageJson = {
|
|
152304
152277
|
dependencies
|
|
152305
152278
|
};
|
|
152279
|
+
function getTagElementSpace(element) {
|
|
152280
|
+
return element.clientWidth + 4;
|
|
152281
|
+
}
|
|
152282
|
+
const createCssVariablesForPadding = memoizeOne$1(
|
|
152283
|
+
(hasIcon, inputPadding, iconSize) => {
|
|
152284
|
+
const rightIconPadding = (inputPadding == null ? void 0 : inputPadding.right) ?? Dim.px(0);
|
|
152285
|
+
return generatePaddingVariableAssignmentStyleObject({
|
|
152286
|
+
...inputPadding,
|
|
152287
|
+
left: hasIcon ? getIconPadding(inputPadding == null ? void 0 : inputPadding.left, iconSize) : (inputPadding == null ? void 0 : inputPadding.left) ?? Dimension.px(0),
|
|
152288
|
+
right: rightIconPadding
|
|
152289
|
+
});
|
|
152290
|
+
}
|
|
152291
|
+
);
|
|
152292
|
+
const getClearableIconRight = memoizeOne$1(
|
|
152293
|
+
(allowClearing, inputPadding, iconSize) => {
|
|
152294
|
+
if (!allowClearing) {
|
|
152295
|
+
return 0;
|
|
152296
|
+
}
|
|
152297
|
+
const iconPadding = getIconPadding(
|
|
152298
|
+
inputPadding == null ? void 0 : inputPadding.right,
|
|
152299
|
+
iconSize ?? DEFAULT_ICON_SIZE$1,
|
|
152300
|
+
false
|
|
152301
|
+
);
|
|
152302
|
+
return iconPadding.value;
|
|
152303
|
+
}
|
|
152304
|
+
);
|
|
152306
152305
|
const DatePickerActionsWrapper = qe$1.div`
|
|
152307
152306
|
display: flex;
|
|
152308
152307
|
justify-content: end;
|
|
@@ -152419,14 +152418,6 @@ const getTimePrecision = (dateFormat) => {
|
|
|
152419
152418
|
const isValidDate = (date4) => {
|
|
152420
152419
|
return date4 !== "Invalid date" && moment(date4).isValid();
|
|
152421
152420
|
};
|
|
152422
|
-
const labelStyleRaw = {
|
|
152423
|
-
vertical: Ae$1`
|
|
152424
|
-
align-self: flex-start;
|
|
152425
|
-
`,
|
|
152426
|
-
horizontal: Ae$1`
|
|
152427
|
-
flex-basis: var(--label-width);
|
|
152428
|
-
`
|
|
152429
|
-
};
|
|
152430
152421
|
const StyledControlGroup$1 = qe$1(ControlGroup)`
|
|
152431
152422
|
height: 100%;
|
|
152432
152423
|
&&& {
|
|
@@ -152721,6 +152712,11 @@ class DatePickerComponent extends React__default.Component {
|
|
|
152721
152712
|
const isInputFocused = this.state.isOpen;
|
|
152722
152713
|
const isVertical = !this.props.labelPosition || this.props.labelPosition === "top";
|
|
152723
152714
|
const errorMessages = this.props.errorMessages;
|
|
152715
|
+
const paddingVarDeclarations = createCssVariablesForPadding(
|
|
152716
|
+
!!this.props.icon,
|
|
152717
|
+
this.props.inputPadding,
|
|
152718
|
+
this.props.iconSize
|
|
152719
|
+
);
|
|
152724
152720
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
152725
152721
|
WidgetErrorsWrapper,
|
|
152726
152722
|
{
|
|
@@ -152753,72 +152749,81 @@ class DatePickerComponent extends React__default.Component {
|
|
|
152753
152749
|
]
|
|
152754
152750
|
}
|
|
152755
152751
|
),
|
|
152756
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
152757
|
-
|
|
152758
|
-
|
|
152759
|
-
{
|
|
152760
|
-
|
|
152761
|
-
|
|
152762
|
-
|
|
152763
|
-
|
|
152764
|
-
|
|
152765
|
-
|
|
152766
|
-
|
|
152767
|
-
|
|
152768
|
-
|
|
152769
|
-
|
|
152770
|
-
|
|
152771
|
-
|
|
152772
|
-
|
|
152773
|
-
|
|
152774
|
-
|
|
152775
|
-
|
|
152776
|
-
|
|
152777
|
-
|
|
152778
|
-
|
|
152779
|
-
|
|
152780
|
-
|
|
152781
|
-
|
|
152782
|
-
|
|
152783
|
-
|
|
152784
|
-
|
|
152785
|
-
|
|
152786
|
-
|
|
152787
|
-
|
|
152788
|
-
|
|
152789
|
-
|
|
152790
|
-
|
|
152791
|
-
|
|
152792
|
-
|
|
152793
|
-
|
|
152794
|
-
|
|
152795
|
-
|
|
152796
|
-
|
|
152752
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
152753
|
+
"div",
|
|
152754
|
+
{
|
|
152755
|
+
style: {
|
|
152756
|
+
...FormInputWithErrorWrapperStyle,
|
|
152757
|
+
...paddingVarDeclarations
|
|
152758
|
+
},
|
|
152759
|
+
children: [
|
|
152760
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
152761
|
+
DateInput3,
|
|
152762
|
+
{
|
|
152763
|
+
dateFnsLocaleLoader: localeLoader,
|
|
152764
|
+
timezone: moment.tz.guess(),
|
|
152765
|
+
formatDate: this.formatDisplayDate,
|
|
152766
|
+
placeholder: this.props.placeholder,
|
|
152767
|
+
disabled: this.props.isDisabled,
|
|
152768
|
+
className: `${CLASS_NAMES.DATEPICKER} ${this.state.isOpen ? CLASS_NAMES.POPOVER_WRAPPER : ""} ${this.shouldWrapTime() ? "sb-datepicker-wrapped-time" : ""}`,
|
|
152769
|
+
showActionsBar: false,
|
|
152770
|
+
dayPickerProps: {
|
|
152771
|
+
formatters: {
|
|
152772
|
+
formatMonthCaption: (date4) => date4.toLocaleString("default", { month: "short" })
|
|
152773
|
+
},
|
|
152774
|
+
onSelect: this.onDayChanged,
|
|
152775
|
+
footer: this.getPopoverFooter()
|
|
152776
|
+
},
|
|
152777
|
+
timePickerProps: !showTime ? void 0 : {
|
|
152778
|
+
precision: timePrecision,
|
|
152779
|
+
useAmPm: !this.props.twentyFourHourTime,
|
|
152780
|
+
onChange: this.onTimeChanged
|
|
152781
|
+
},
|
|
152782
|
+
value: currentValue,
|
|
152783
|
+
initialMonth,
|
|
152784
|
+
minDate,
|
|
152785
|
+
maxDate,
|
|
152786
|
+
closeOnSelection: false,
|
|
152787
|
+
inputProps: {
|
|
152788
|
+
className: `${CLASS_NAMES.INPUT} ${this.props.inputClassName ?? ""} ${inputClassNames}`,
|
|
152789
|
+
style: {
|
|
152790
|
+
...this.props.inputStyleOverride,
|
|
152791
|
+
minHeight: this.props.inputLineHeightPx ? `${this.props.inputLineHeightPx + INPUT_ADDITIONAL_MIN_HEIGHT$1}px` : void 0
|
|
152792
|
+
},
|
|
152793
|
+
onClick: this.props.onInputClick,
|
|
152794
|
+
leftElement: this.props.icon ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
152795
|
+
"div",
|
|
152797
152796
|
{
|
|
152798
|
-
|
|
152799
|
-
|
|
152797
|
+
className: `IconWrapper ${CLASS_NAMES.ICON} ${isInputFocused ? CLASS_NAMES.ACTIVE_MODIFIER : ""} ${this.props.isDisabled || this.props.selectedDate === "" || this.props.selectedDate == null ? CLASS_NAMES.DISABLED_MODIFIER : ""} ${!this.props.isValid ? CLASS_NAMES.ERROR_MODIFIER : ""}`,
|
|
152798
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
152799
|
+
DynamicSVG,
|
|
152800
|
+
{
|
|
152801
|
+
iconName: this.props.icon,
|
|
152802
|
+
size: this.props.iconSize ?? DEFAULT_ICON_SIZE$1
|
|
152803
|
+
}
|
|
152804
|
+
)
|
|
152800
152805
|
}
|
|
152801
|
-
)
|
|
152806
|
+
) : void 0,
|
|
152807
|
+
// @ts-expect-error extra props
|
|
152808
|
+
"data-invalid": !this.props.isValid && !this.state.isOpen,
|
|
152809
|
+
"data-active": this.state.isOpen,
|
|
152810
|
+
rightElement: !formatIncludesTimezone(displayFormat) && this.props.showTimezone ? /* @__PURE__ */ jsxRuntimeExports.jsx(Timezone, { timezone: this.displayTimezone }) : void 0,
|
|
152811
|
+
onChange: this.onInputChanged
|
|
152812
|
+
},
|
|
152813
|
+
popoverProps: {
|
|
152814
|
+
...this.props.forceOpen ? { isOpen: this.state.isOpen } : {},
|
|
152815
|
+
onInteraction: this.handleInteraction,
|
|
152816
|
+
className: CLASS_NAMES.DATEPICKER,
|
|
152817
|
+
onClose: this.props.onDatePickerClosed,
|
|
152818
|
+
position: "auto",
|
|
152819
|
+
rootBoundary: "viewport"
|
|
152802
152820
|
}
|
|
152803
|
-
|
|
152804
|
-
|
|
152805
|
-
|
|
152806
|
-
|
|
152807
|
-
|
|
152808
|
-
|
|
152809
|
-
},
|
|
152810
|
-
popoverProps: {
|
|
152811
|
-
...this.props.forceOpen ? { isOpen: this.state.isOpen } : {},
|
|
152812
|
-
onInteraction: this.handleInteraction,
|
|
152813
|
-
className: CLASS_NAMES.DATEPICKER,
|
|
152814
|
-
onClose: this.props.onDatePickerClosed,
|
|
152815
|
-
position: "auto",
|
|
152816
|
-
rootBoundary: "viewport"
|
|
152817
|
-
}
|
|
152818
|
-
}
|
|
152819
|
-
),
|
|
152820
|
-
inlineError
|
|
152821
|
-
] })
|
|
152821
|
+
}
|
|
152822
|
+
),
|
|
152823
|
+
inlineError
|
|
152824
|
+
]
|
|
152825
|
+
}
|
|
152826
|
+
)
|
|
152822
152827
|
]
|
|
152823
152828
|
}
|
|
152824
152829
|
)
|
|
@@ -179631,32 +179636,6 @@ Fuse.config = Config;
|
|
|
179631
179636
|
{
|
|
179632
179637
|
register3(ExtendedSearch);
|
|
179633
179638
|
}
|
|
179634
|
-
function getTagElementSpace(element) {
|
|
179635
|
-
return element.clientWidth + 4;
|
|
179636
|
-
}
|
|
179637
|
-
const createCssVariablesForPadding = memoizeOne$1(
|
|
179638
|
-
(hasIcon, inputPadding, iconSize) => {
|
|
179639
|
-
const rightIconPadding = (inputPadding == null ? void 0 : inputPadding.right) ?? Dim.px(0);
|
|
179640
|
-
return generatePaddingVariableAssignmentStyleObject({
|
|
179641
|
-
...inputPadding,
|
|
179642
|
-
left: hasIcon ? getIconPadding(inputPadding == null ? void 0 : inputPadding.left, iconSize) : (inputPadding == null ? void 0 : inputPadding.left) ?? Dimension.px(0),
|
|
179643
|
-
right: rightIconPadding
|
|
179644
|
-
});
|
|
179645
|
-
}
|
|
179646
|
-
);
|
|
179647
|
-
const getClearableIconRight = memoizeOne$1(
|
|
179648
|
-
(allowClearing, inputPadding, iconSize) => {
|
|
179649
|
-
if (!allowClearing) {
|
|
179650
|
-
return 0;
|
|
179651
|
-
}
|
|
179652
|
-
const iconPadding = getIconPadding(
|
|
179653
|
-
inputPadding == null ? void 0 : inputPadding.right,
|
|
179654
|
-
iconSize ?? DEFAULT_ICON_SIZE$1,
|
|
179655
|
-
false
|
|
179656
|
-
);
|
|
179657
|
-
return iconPadding.value;
|
|
179658
|
-
}
|
|
179659
|
-
);
|
|
179660
179639
|
const TAG_HEIGHT = 26;
|
|
179661
179640
|
const INPUT_SIZE = 36;
|
|
179662
179641
|
const MORE_TAGS_SIZE = 90;
|
|
@@ -180646,17 +180625,6 @@ const normalizeFunction = (val, transformationValue) => {
|
|
|
180646
180625
|
}
|
|
180647
180626
|
return String(val);
|
|
180648
180627
|
};
|
|
180649
|
-
const baseTextStyleProp = createTextStyleCompositeBase();
|
|
180650
|
-
const textStyle = textStyleProp({
|
|
180651
|
-
baseProp: baseTextStyleProp
|
|
180652
|
-
}).default(
|
|
180653
|
-
() => ({
|
|
180654
|
-
variant: DEFAULT_INPUT_WIDGET_INPUT_STYLE_VARIANT,
|
|
180655
|
-
textColor: {
|
|
180656
|
-
default: Theme.colors.neutral900
|
|
180657
|
-
}
|
|
180658
|
-
})
|
|
180659
|
-
);
|
|
180660
180628
|
const propertiesDefinition$8 = {
|
|
180661
180629
|
general: Section.category(PropsPanelCategory.Content).children({
|
|
180662
180630
|
label: Prop.string().readAndWrite().default("").propertiesPanel({
|
|
@@ -180711,7 +180679,7 @@ const propertiesDefinition$8 = {
|
|
|
180711
180679
|
label: "Placeholder",
|
|
180712
180680
|
helpText: "Text to be shown inside of placeholder"
|
|
180713
180681
|
}),
|
|
180714
|
-
textStyle,
|
|
180682
|
+
textStyle: inputTextStyle(),
|
|
180715
180683
|
loadingAnimation: Prop.boolean().propertiesPanel({
|
|
180716
180684
|
label: "Loading animation",
|
|
180717
180685
|
helpText: "Display a loading animation if dependent data is loading"
|
|
@@ -181621,20 +181589,25 @@ const propertiesDefinition$6 = {
|
|
|
181621
181589
|
controlType: "SWITCH"
|
|
181622
181590
|
})
|
|
181623
181591
|
}),
|
|
181624
|
-
layout: Section.category(PropsPanelCategory.Layout).add({
|
|
181592
|
+
layout: Section.category(PropsPanelCategory.Layout).add(padding({ themeValue: DROPDOWN_PADDING, default: DROPDOWN_PADDING })).add({
|
|
181625
181593
|
...size$2(),
|
|
181626
181594
|
...widthWithoutFit()
|
|
181627
181595
|
}).add(margin()).add(visible()),
|
|
181628
181596
|
appearance: Section.category(PropsPanelCategory.Appearance).children({
|
|
181629
181597
|
labelPosition: labelPosition(),
|
|
181630
181598
|
labelStyle: labelTextStyle(),
|
|
181631
|
-
// TODO(code-mode): Add color pickers, border controls, etc.
|
|
181632
181599
|
icon: Prop.string().readAndWrite().default("calendar_today").propertiesPanel({
|
|
181633
181600
|
label: "Icon",
|
|
181634
181601
|
helpText: "The icon to display",
|
|
181635
181602
|
controlType: "ICON_SELECTOR",
|
|
181636
|
-
isRemovable: true
|
|
181637
|
-
|
|
181603
|
+
isRemovable: true,
|
|
181604
|
+
visibility: "SHOW_NAME"
|
|
181605
|
+
}),
|
|
181606
|
+
placeholder: Prop.string().default("Select date").propertiesPanel({
|
|
181607
|
+
label: "Placeholder",
|
|
181608
|
+
helpText: "Text to be shown inside of placeholder"
|
|
181609
|
+
}),
|
|
181610
|
+
textStyle: inputTextStyle()
|
|
181638
181611
|
}),
|
|
181639
181612
|
interaction: Section.category(PropsPanelCategory.Interaction).children({
|
|
181640
181613
|
isRequired: Prop.boolean().readAndWrite().default(false).propertiesPanel({
|
|
@@ -181769,6 +181742,10 @@ const SbDatePicker = registerSbComponent(
|
|
|
181769
181742
|
return Object.values(errors2).filter(Boolean);
|
|
181770
181743
|
}, [props2.showError, props2.validationErrors]);
|
|
181771
181744
|
const labelProps = useLabelProps(props2);
|
|
181745
|
+
const inputProps = useInputTypographyProps({
|
|
181746
|
+
backgroundColor: props2.backgroundColor,
|
|
181747
|
+
textStyle: props2.textStyle
|
|
181748
|
+
});
|
|
181772
181749
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(DatePickerContainer, { ...passThroughProps, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
181773
181750
|
DatePickerComponent,
|
|
181774
181751
|
{
|
|
@@ -181791,7 +181768,10 @@ const SbDatePicker = registerSbComponent(
|
|
|
181791
181768
|
showTimezone: !!props2.manageTimezone,
|
|
181792
181769
|
icon: props2.icon,
|
|
181793
181770
|
onDatePickerClosed: handleDatePickerClosed,
|
|
181771
|
+
placeholder: props2.placeholder,
|
|
181794
181772
|
labelStyleOverride: labelProps == null ? void 0 : labelProps.style,
|
|
181773
|
+
inputStyleOverride: inputProps.style,
|
|
181774
|
+
inputPadding: props2.padding,
|
|
181795
181775
|
labelPosition: props2.labelPosition,
|
|
181796
181776
|
errorMessagePlacement: props2.errorMessagePlacement,
|
|
181797
181777
|
errorMessages,
|
|
@@ -196718,4 +196698,4 @@ export {
|
|
|
196718
196698
|
copyToClipboard as y,
|
|
196719
196699
|
navigateTo as z
|
|
196720
196700
|
};
|
|
196721
|
-
//# sourceMappingURL=index-
|
|
196701
|
+
//# sourceMappingURL=index-D_-27jtA.js.map
|