@appquality/unguess-design-system 2.8.18 → 2.8.21
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/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,41 @@
|
|
|
1
|
+
# v2.8.21 (Fri Apr 15 2022)
|
|
2
|
+
|
|
3
|
+
#### 🐛 Bug Fix
|
|
4
|
+
|
|
5
|
+
- fix(dropdown-menu): set auto width for dropdown menu list detached fr… [#36](https://github.com/AppQuality/unguess-design-system/pull/36) ([@marcbon](https://github.com/marcbon))
|
|
6
|
+
|
|
7
|
+
#### Authors: 1
|
|
8
|
+
|
|
9
|
+
- Marco Bonomo ([@marcbon](https://github.com/marcbon))
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
# v2.8.20 (Fri Apr 15 2022)
|
|
14
|
+
|
|
15
|
+
#### 🐛 Bug Fix
|
|
16
|
+
|
|
17
|
+
- fix(campaign-cards): add tag max-width [#35](https://github.com/AppQuality/unguess-design-system/pull/35) ([@marcbon](https://github.com/marcbon))
|
|
18
|
+
|
|
19
|
+
#### Authors: 1
|
|
20
|
+
|
|
21
|
+
- Marco Bonomo ([@marcbon](https://github.com/marcbon))
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
# v2.8.19 (Thu Apr 14 2022)
|
|
26
|
+
|
|
27
|
+
#### 🐛 Bug Fix
|
|
28
|
+
|
|
29
|
+
- feat(sidebar): add vertical scroll [#33](https://github.com/AppQuality/unguess-design-system/pull/33) ([@marcbon](https://github.com/marcbon))
|
|
30
|
+
- feat(mediainput): add rich input component with mediaIcon support [#34](https://github.com/AppQuality/unguess-design-system/pull/34) ([@cannarocks](https://github.com/cannarocks))
|
|
31
|
+
|
|
32
|
+
#### Authors: 2
|
|
33
|
+
|
|
34
|
+
- Luca Cannarozzo ([@cannarocks](https://github.com/cannarocks))
|
|
35
|
+
- Marco Bonomo ([@marcbon](https://github.com/marcbon))
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
1
39
|
# v2.8.18 (Thu Apr 14 2022)
|
|
2
40
|
|
|
3
41
|
#### ⚠️ Pushed to `master`
|
package/build/index.d.ts
CHANGED
|
@@ -19,6 +19,7 @@ export * from "./stories/dropdowns/select";
|
|
|
19
19
|
export * from "./stories/forms/checkbox";
|
|
20
20
|
export * as FormField from "./stories/forms/field";
|
|
21
21
|
export * from "./stories/forms/input";
|
|
22
|
+
export * from "./stories/forms/mediaInput";
|
|
22
23
|
export * from "./stories/forms/radio";
|
|
23
24
|
export * from "./stories/forms/textarea";
|
|
24
25
|
export * from "./stories/forms/toggle";
|
package/build/index.js
CHANGED
|
@@ -232,8 +232,8 @@ var gradients = {
|
|
|
232
232
|
|
|
233
233
|
var theme = __assign(__assign({}, reactTheming.DEFAULT_THEME), { palette: palette, fonts: __assign(__assign({}, reactTheming.DEFAULT_THEME.fonts), { system: '"Poppins",sans-serif,Helvetica,Arial,sans-serif' }), gradients: gradients, borderRadii: __assign(__assign({}, reactTheming.DEFAULT_THEME.borderRadii), { lg: "8px" }), components: __assign(__assign({}, reactTheming.DEFAULT_THEME.components), { Headers: __assign(__assign({}, reactTheming.DEFAULT_THEME.components.Headers), { height: "64px" }) }), shadows: __assign(__assign({}, reactTheming.DEFAULT_THEME.shadows), { boxShadow: boxShadow }) });
|
|
234
234
|
|
|
235
|
-
var GlobalStyle = styled.createGlobalStyle(templateObject_1$
|
|
236
|
-
var templateObject_1$
|
|
235
|
+
var GlobalStyle = styled.createGlobalStyle(templateObject_1$O || (templateObject_1$O = __makeTemplateObject(["\n body {\n font-family: ", ";\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n }\n \n svg {\n max-height: 100%;\n }\n \n "], ["\n body {\n font-family: ", ";\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n }\n \n svg {\n max-height: 100%;\n }\n \n "])), theme.fonts.system);
|
|
236
|
+
var templateObject_1$O;
|
|
237
237
|
|
|
238
238
|
/**
|
|
239
239
|
* Accordions are headers that can be expanded to reveal content or collapsed to hide it.
|
|
@@ -249,7 +249,7 @@ Accordion.Label = reactAccordions.Accordion.Label;
|
|
|
249
249
|
Accordion.Panel = reactAccordions.Accordion.Panel;
|
|
250
250
|
|
|
251
251
|
// import useWindowSize from "../../hooks/useWindowSize";
|
|
252
|
-
var UgAvatar = styled__default["default"](reactAvatars.Avatar)(templateObject_1$
|
|
252
|
+
var UgAvatar = styled__default["default"](reactAvatars.Avatar)(templateObject_1$N || (templateObject_1$N = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (props) {
|
|
253
253
|
return "\n background: ".concat(props.backgroundColor || theme.gradients.dark, ";\n ");
|
|
254
254
|
});
|
|
255
255
|
/**
|
|
@@ -272,7 +272,7 @@ var Avatar = function (props) {
|
|
|
272
272
|
return (jsxRuntime.jsx(UgAvatar, __assign({}, props, { badge: fixedBadge, children: wrapChildren(props.avatarType || "text"), size: props.size || "small" })));
|
|
273
273
|
};
|
|
274
274
|
Avatar.Text = UgAvatar.Text;
|
|
275
|
-
var templateObject_1$
|
|
275
|
+
var templateObject_1$N;
|
|
276
276
|
|
|
277
277
|
/**
|
|
278
278
|
* Breadcrumbs mark and communicate a user’s location in the product.
|
|
@@ -293,7 +293,7 @@ var Breadcrumb = function (props) { return jsxRuntime.jsx(reactBreadcrumbs.Bread
|
|
|
293
293
|
*/
|
|
294
294
|
var Anchor = function (props) { return jsxRuntime.jsx(reactButtons.Anchor, __assign({}, props)); };
|
|
295
295
|
|
|
296
|
-
var UgButton = styled__default["default"](reactButtons.Button)(templateObject_1$
|
|
296
|
+
var UgButton = styled__default["default"](reactButtons.Button)(templateObject_1$M || (templateObject_1$M = __makeTemplateObject([""], [""])));
|
|
297
297
|
/**
|
|
298
298
|
* Buttons let users take action quickly.
|
|
299
299
|
* Use a Button to enable actions or decisions that are important to a user’s workflow.
|
|
@@ -305,7 +305,7 @@ var UgButton = styled__default["default"](reactButtons.Button)(templateObject_1$
|
|
|
305
305
|
var Button = function (props) { return jsxRuntime.jsx(UgButton, __assign({}, props)); };
|
|
306
306
|
Button.StartIcon = UgButton.StartIcon;
|
|
307
307
|
Button.EndIcon = UgButton.EndIcon;
|
|
308
|
-
var templateObject_1$
|
|
308
|
+
var templateObject_1$M;
|
|
309
309
|
|
|
310
310
|
/**
|
|
311
311
|
A Button group lets users make a selection from a set of options.
|
|
@@ -358,13 +358,13 @@ var Tag = function (props) { return jsxRuntime.jsx(reactTags.Tag, __assign({}, p
|
|
|
358
358
|
Tag.Avatar = reactTags.Tag.Avatar;
|
|
359
359
|
Tag.Close = reactTags.Tag.Close;
|
|
360
360
|
|
|
361
|
-
var UgLabel = styled__default["default"](reactForms.Label)(templateObject_1$
|
|
361
|
+
var UgLabel = styled__default["default"](reactForms.Label)(templateObject_1$L || (templateObject_1$L = __makeTemplateObject([""], [""])));
|
|
362
362
|
/**
|
|
363
363
|
* A Label is used to specify a title for an input.
|
|
364
364
|
* <hr>
|
|
365
365
|
**/
|
|
366
366
|
var Label = function (props) { return jsxRuntime.jsx(UgLabel, __assign({}, props)); };
|
|
367
|
-
var templateObject_1$
|
|
367
|
+
var templateObject_1$L;
|
|
368
368
|
|
|
369
369
|
var _g$4, _path$p, _path2$7, _path3$6, _path4$4, _path5$3, _path6$3, _path7$3, _path8$3, _path9$3, _path10$3, _path11$2;
|
|
370
370
|
|
|
@@ -593,8 +593,8 @@ var getTypeData = function (type) {
|
|
|
593
593
|
};
|
|
594
594
|
}
|
|
595
595
|
};
|
|
596
|
-
var Wrapper = styled__default["default"](Card)(templateObject_1$
|
|
597
|
-
var StyledTag$1 = styled__default["default"](Tag)(templateObject_2$
|
|
596
|
+
var Wrapper = styled__default["default"](Card)(templateObject_1$K || (templateObject_1$K = __makeTemplateObject(["\n border-radius: ", ";\n padding: 1rem;\n border: 1px solid ", ";\n display: flex;\n flex-direction: column;\n height: 100%;\n\n &:hover {\n box-shadow: ", ";\n }\n"], ["\n border-radius: ", ";\n padding: 1rem;\n border: 1px solid ", ";\n display: flex;\n flex-direction: column;\n height: 100%;\n\n &:hover {\n box-shadow: ", ";\n }\n"])), theme.borderRadii.lg, theme.palette.grey["200"], theme.shadows.boxShadow(theme));
|
|
597
|
+
var StyledTag$1 = styled__default["default"](Tag)(templateObject_2$c || (templateObject_2$c = __makeTemplateObject(["\n color: ", ";\n max-width: 75%;\n"], ["\n color: ", ";\n max-width: 75%;\n"])), theme.palette.grey["700"]);
|
|
598
598
|
var StyledTagNew = styled__default["default"](Tag)(templateObject_3$6 || (templateObject_3$6 = __makeTemplateObject(["\n height: ", "px;\n padding: ", "px ", "px;\n color: ", ";\n"], ["\n height: ", "px;\n padding: ", "px ", "px;\n color: ", ";\n"])), function (_a) {
|
|
599
599
|
var theme = _a.theme;
|
|
600
600
|
return theme.space.base * 6;
|
|
@@ -602,7 +602,7 @@ var StyledTagNew = styled__default["default"](Tag)(templateObject_3$6 || (templa
|
|
|
602
602
|
var theme = _a.theme;
|
|
603
603
|
return theme.space.base * 2;
|
|
604
604
|
}, theme.palette.white);
|
|
605
|
-
var StyledLabel = styled__default["default"](Label)(templateObject_4$3 || (templateObject_4$3 = __makeTemplateObject(["\n font-size: ", ";\n color: ", "
|
|
605
|
+
var StyledLabel = styled__default["default"](Label)(templateObject_4$3 || (templateObject_4$3 = __makeTemplateObject(["\n font-size: ", ";\n color: ", ";\n"], ["\n font-size: ", ";\n color: ", ";\n"])), theme.fontSizes.sm, theme.palette.grey["500"]);
|
|
606
606
|
var StyledTitleLabel = styled__default["default"](Label)(templateObject_5$1 || (templateObject_5$1 = __makeTemplateObject(["\n color: ", ";\n font-size: ", ";\n word-wrap: break-word;\n"], ["\n color: ", ";\n font-size: ", ";\n word-wrap: break-word;\n"])), theme.palette.blue["600"], theme.fontSizes.lg);
|
|
607
607
|
var Divider = styled__default["default"].div(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n width: 100%;\n height: 1px;\n margin: ", " 0;\n background-color: ", ";\n"], ["\n width: 100%;\n height: 1px;\n margin: ", " 0;\n background-color: ", ";\n"])), theme.space.lg, theme.palette.grey["300"]);
|
|
608
608
|
var CardHeader = styled__default["default"].div(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n flex-direction: row;\n justify-content: space-between;\n height: ", "px;\n"], ["\n display: flex;\n align-items: center;\n flex-direction: row;\n justify-content: space-between;\n height: ", "px;\n"])), theme.space.base * 6);
|
|
@@ -624,7 +624,7 @@ var CampaignCard = function (props) {
|
|
|
624
624
|
return jsxRuntime.jsxs(Wrapper, __assign({}, props, { children: [jsxRuntime.jsxs(CardHeader, { children: [jsxRuntime.jsx(StyledLabel, __assign({ isRegular: true }, { children: date })), isNew && (jsxRuntime.jsx(StyledTagNew, __assign({ hue: theme.palette.fuschia["600"], isPill: true, size: "medium", title: labelNew ? labelNew : "New!" }, { children: labelNew ? labelNew : "New!" })))] }), jsxRuntime.jsxs(CardBody, { children: [jsxRuntime.jsx(StyledLabel, __assign({ isRegular: true }, { children: projectTitleCut })), jsxRuntime.jsx(StyledTitleLabel, __assign({ isRegular: true }, { children: campaignTitleCut }))] }), jsxRuntime.jsx(Divider, {}), jsxRuntime.jsxs(CardFooter, { children: [typeData &&
|
|
625
625
|
jsxRuntime.jsxs(StyledTag$1, __assign({ size: "large", isPill: true, isRegular: true, hue: theme.palette.grey[100] }, { children: [jsxRuntime.jsx(Tag.Avatar, { children: jsxRuntime.jsx(PillIcon, {}) }), props.pillText] })), jsxRuntime.jsx(StatusIcon, {})] })] }));
|
|
626
626
|
};
|
|
627
|
-
var templateObject_1$
|
|
627
|
+
var templateObject_1$K, templateObject_2$c, templateObject_3$6, templateObject_4$3, templateObject_5$1, templateObject_6, templateObject_7, templateObject_8, templateObject_9;
|
|
628
628
|
|
|
629
629
|
/**
|
|
630
630
|
* Title is a basic component used to display a title. Often used in card headers.
|
|
@@ -830,7 +830,7 @@ var SvgCampaignExperiential = function SvgCampaignExperiential(props) {
|
|
|
830
830
|
})));
|
|
831
831
|
};
|
|
832
832
|
|
|
833
|
-
var StyledTag = styled__default["default"](Tag)(templateObject_1$
|
|
833
|
+
var StyledTag = styled__default["default"](Tag)(templateObject_1$J || (templateObject_1$J = __makeTemplateObject(["\n background-color: transparent;\n pointer-events: none;\n font-weight: ", ";\n ", "\n svg {\n margin-right: ", " !important;\n }\n\n span {\n font-weight: ", ";\n margin-left: ", ";\n color: ", ";\n }\n"], ["\n background-color: transparent;\n pointer-events: none;\n font-weight: ", ";\n ", "\n svg {\n margin-right: ", " !important;\n }\n\n span {\n font-weight: ", ";\n margin-left: ", ";\n color: ", ";\n }\n"])), function (_a) {
|
|
834
834
|
var theme = _a.theme;
|
|
835
835
|
return theme.fontWeights.regular;
|
|
836
836
|
}, function (_a) {
|
|
@@ -866,24 +866,24 @@ var Counter = function (props) {
|
|
|
866
866
|
return (jsxRuntime.jsxs(StyledTag, __assign({}, props, { size: props.size || "large" }, { children: [jsxRuntime.jsx(StyledTag.Avatar, { children: jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [status === "completed" && jsxRuntime.jsx(SvgCampaignCompleted, {}), status === "progress" && jsxRuntime.jsx(SvgCampaignProgress, {}), status === "incoming" && jsxRuntime.jsx(SvgCampaignIncoming, {}), status === "functional" && jsxRuntime.jsx(SvgCampaignFunctional, {}), status === "experiential" && jsxRuntime.jsx(SvgCampaignExperiential, {})] }) }), props.children, props.counter !== undefined && jsxRuntime.jsx("span", { children: props.counter })] })));
|
|
867
867
|
};
|
|
868
868
|
Counter.Avatar = StyledTag.Avatar;
|
|
869
|
-
var templateObject_1$
|
|
869
|
+
var templateObject_1$J;
|
|
870
870
|
|
|
871
|
-
var Field$1 = styled__default["default"](reactDropdowns.Field)(templateObject_1$
|
|
872
|
-
var templateObject_1$
|
|
871
|
+
var Field$1 = styled__default["default"](reactDropdowns.Field)(templateObject_1$I || (templateObject_1$I = __makeTemplateObject([""], [""])));
|
|
872
|
+
var templateObject_1$I;
|
|
873
873
|
|
|
874
874
|
var index$1 = /*#__PURE__*/Object.freeze({
|
|
875
875
|
__proto__: null,
|
|
876
876
|
Field: Field$1
|
|
877
877
|
});
|
|
878
878
|
|
|
879
|
-
var UgItem = styled__default["default"](reactDropdowns.Item)(templateObject_1$
|
|
879
|
+
var UgItem = styled__default["default"](reactDropdowns.Item)(templateObject_1$H || (templateObject_1$H = __makeTemplateObject(["\n &[disabled] svg {\n opacity: 0.5;\n }\n &:hover {\n background-color: ", ";\n }\n"], ["\n &[disabled] svg {\n opacity: 0.5;\n }\n &:hover {\n background-color: ", ";\n }\n"])), function (_a) {
|
|
880
880
|
var theme = _a.theme;
|
|
881
881
|
return theme.palette.blue[100];
|
|
882
882
|
});
|
|
883
883
|
var Item = function (props) { return jsxRuntime.jsx(UgItem, __assign({}, props)); };
|
|
884
|
-
var templateObject_1$
|
|
884
|
+
var templateObject_1$H;
|
|
885
885
|
|
|
886
|
-
var UgMenu = styled__default["default"](reactDropdowns.Menu)(templateObject_1$
|
|
886
|
+
var UgMenu = styled__default["default"](reactDropdowns.Menu)(templateObject_1$G || (templateObject_1$G = __makeTemplateObject(["\n width: auto;\n min-width: 100%;\n"], ["\n width: auto;\n min-width: 100%;\n"])));
|
|
887
887
|
/**
|
|
888
888
|
* A Menu is a wrapper for items elements
|
|
889
889
|
**/
|
|
@@ -896,7 +896,7 @@ var ItemMeta = function (props) { return jsxRuntime.jsx(reactDropdowns.ItemMeta,
|
|
|
896
896
|
var MediaBody = function (props) { return jsxRuntime.jsx(reactDropdowns.MediaBody, __assign({}, props)); };
|
|
897
897
|
var MediaFigure = function (props) { return jsxRuntime.jsx(reactDropdowns.MediaFigure, __assign({}, props)); };
|
|
898
898
|
var MediaItem = function (props) { return jsxRuntime.jsx(reactDropdowns.MediaItem, __assign({}, props)); };
|
|
899
|
-
var templateObject_1$
|
|
899
|
+
var templateObject_1$G;
|
|
900
900
|
|
|
901
901
|
/**
|
|
902
902
|
* Multiselect lets users select multiple items from a list. Options are dynamically filtered as a user types in the input field and their selections appear as tags in the input field.
|
|
@@ -907,7 +907,7 @@ var templateObject_1$F;
|
|
|
907
907
|
*/
|
|
908
908
|
var Multiselect = function (props) { return (jsxRuntime.jsx(reactDropdowns.Multiselect, __assign({}, props))); };
|
|
909
909
|
|
|
910
|
-
var UgSelect = styled__default["default"](reactDropdowns.Select)(templateObject_1$
|
|
910
|
+
var UgSelect = styled__default["default"](reactDropdowns.Select)(templateObject_1$F || (templateObject_1$F = __makeTemplateObject(["\n ", "\n"], ["\n ", "\n"])), function (props) {
|
|
911
911
|
return props.isPrimary &&
|
|
912
912
|
"\n background-color: ".concat(props.theme.palette.blue[600], ";\n color: white;\n & svg[data-garden-id=\"forms.media_figure\"] {\n color: white;\n }\n ");
|
|
913
913
|
});
|
|
@@ -924,9 +924,9 @@ var UgSelect = styled__default["default"](reactDropdowns.Select)(templateObject_
|
|
|
924
924
|
var Select = function (props) { return jsxRuntime.jsx(UgSelect, __assign({}, props)); };
|
|
925
925
|
var Dropdown = function (props) { return (jsxRuntime.jsx(reactDropdowns.Dropdown, __assign({}, props))); };
|
|
926
926
|
var Message = function (props) { return jsxRuntime.jsx(reactDropdowns.Message, __assign({}, props)); };
|
|
927
|
-
var templateObject_1$
|
|
927
|
+
var templateObject_1$F;
|
|
928
928
|
|
|
929
|
-
var UgCheckbox = styled__default["default"](reactForms.Checkbox)(templateObject_1$
|
|
929
|
+
var UgCheckbox = styled__default["default"](reactForms.Checkbox)(templateObject_1$E || (templateObject_1$E = __makeTemplateObject([""], [""])));
|
|
930
930
|
/**
|
|
931
931
|
* A Checkbox lets users select and unselect options from a list.
|
|
932
932
|
* <hr>
|
|
@@ -938,14 +938,14 @@ var UgCheckbox = styled__default["default"](reactForms.Checkbox)(templateObject_
|
|
|
938
938
|
* - To let users activate an option that takes effect immediately, use a Toggle instead
|
|
939
939
|
**/
|
|
940
940
|
var Checkbox = function (props) { return jsxRuntime.jsx(UgCheckbox, __assign({}, props)); };
|
|
941
|
-
var templateObject_1$
|
|
941
|
+
var templateObject_1$E;
|
|
942
942
|
|
|
943
|
-
var UgField = styled__default["default"](reactForms.Field)(templateObject_1$
|
|
943
|
+
var UgField = styled__default["default"](reactForms.Field)(templateObject_1$D || (templateObject_1$D = __makeTemplateObject([""], [""])));
|
|
944
944
|
/**
|
|
945
945
|
* A Field is a wrapper for input elements
|
|
946
946
|
**/
|
|
947
947
|
var Field = function (props) { return jsxRuntime.jsx(UgField, __assign({}, props)); };
|
|
948
|
-
var templateObject_1$
|
|
948
|
+
var templateObject_1$D;
|
|
949
949
|
|
|
950
950
|
var index = /*#__PURE__*/Object.freeze({
|
|
951
951
|
__proto__: null,
|
|
@@ -953,7 +953,7 @@ var index = /*#__PURE__*/Object.freeze({
|
|
|
953
953
|
Hint: reactForms.Hint
|
|
954
954
|
});
|
|
955
955
|
|
|
956
|
-
var UgInput = styled__default["default"](reactForms.Input)(templateObject_1$
|
|
956
|
+
var UgInput = styled__default["default"](reactForms.Input)(templateObject_1$C || (templateObject_1$C = __makeTemplateObject([""], [""])));
|
|
957
957
|
/**
|
|
958
958
|
* An Input lets users enter text into a field.
|
|
959
959
|
* <hr>
|
|
@@ -962,6 +962,17 @@ var UgInput = styled__default["default"](reactForms.Input)(templateObject_1$B ||
|
|
|
962
962
|
* - To enter multiline text, use a Textarea
|
|
963
963
|
**/
|
|
964
964
|
var Input = function (props) { return jsxRuntime.jsx(UgInput, __assign({}, props)); };
|
|
965
|
+
var templateObject_1$C;
|
|
966
|
+
|
|
967
|
+
var UgMediaInput = styled__default["default"](reactForms.MediaInput)(templateObject_1$B || (templateObject_1$B = __makeTemplateObject([""], [""])));
|
|
968
|
+
/**
|
|
969
|
+
* Media elements add even more context to an input.
|
|
970
|
+
* <hr>
|
|
971
|
+
* Used for this:
|
|
972
|
+
* - To let the user enter data into a field
|
|
973
|
+
* - To enter multiline text, use a Textarea
|
|
974
|
+
**/
|
|
975
|
+
var MediaInput = function (props) { return jsxRuntime.jsx(UgMediaInput, __assign({}, props)); };
|
|
965
976
|
var templateObject_1$B;
|
|
966
977
|
|
|
967
978
|
var UgRadio = styled__default["default"](reactForms.Radio)(templateObject_1$A || (templateObject_1$A = __makeTemplateObject([""], [""])));
|
|
@@ -1275,7 +1286,7 @@ var LogoIconContainer = styled__default["default"](reactChrome.HeaderItem)(templ
|
|
|
1275
1286
|
var theme = _a.theme;
|
|
1276
1287
|
return theme.breakpoints.sm;
|
|
1277
1288
|
});
|
|
1278
|
-
var BrandName = styled__default["default"](reactChrome.HeaderItem)(templateObject_2$
|
|
1289
|
+
var BrandName = styled__default["default"](reactChrome.HeaderItem)(templateObject_2$b || (templateObject_2$b = __makeTemplateObject(["\n margin-right: auto;\n margin-left: -8px;\n color: ", ";\n pointer-events: none;\n font-family: ", ";\n @media (max-width: ", ") {\n display: none;\n }\n"], ["\n margin-right: auto;\n margin-left: -8px;\n color: ", ";\n pointer-events: none;\n font-family: ", ";\n @media (max-width: ", ") {\n display: none;\n }\n"])), function (_a) {
|
|
1279
1290
|
var theme = _a.theme;
|
|
1280
1291
|
return theme.palette.blue["600"];
|
|
1281
1292
|
}, function (_a) {
|
|
@@ -1295,7 +1306,7 @@ var MenuItem$1 = styled__default["default"](reactChrome.HeaderItem)(templateObje
|
|
|
1295
1306
|
var BrandItem = function (props) {
|
|
1296
1307
|
return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsxs(MenuItem$1, __assign({}, props, { onClick: props.toggleMenu }, { children: [jsxRuntime.jsx(HeaderItemIcon, { children: jsxRuntime.jsx(SvgMenuStroke, {}) }), props.menuLabel && jsxRuntime.jsx(HeaderItemText, { children: props.menuLabel })] })), jsxRuntime.jsx(LogoIconContainer, __assign({}, props, { hasLogo: true }, { children: jsxRuntime.jsx(HeaderItemIcon, { children: jsxRuntime.jsx(Logo, { type: "icon", size: 150 }) }) })), props.brandName && (jsxRuntime.jsx(BrandName, __assign({}, props, { children: jsxRuntime.jsx(HeaderItemText, { children: props.brandName }) })))] }));
|
|
1297
1308
|
};
|
|
1298
|
-
var templateObject_1$p, templateObject_2$
|
|
1309
|
+
var templateObject_1$p, templateObject_2$b, templateObject_3$5;
|
|
1299
1310
|
|
|
1300
1311
|
var UgHeader = styled__default["default"](reactChrome.Header)(templateObject_1$o || (templateObject_1$o = __makeTemplateObject(["\n height: ", ";\n"], ["\n height: ", ";\n"])), theme.components.Headers.height);
|
|
1301
1312
|
/**
|
|
@@ -1377,7 +1388,7 @@ var Nav = function (props) { return jsxRuntime.jsx(UgNav, __assign({}, props));
|
|
|
1377
1388
|
var templateObject_1$l;
|
|
1378
1389
|
|
|
1379
1390
|
var SelectedItemStyle = styled.css(templateObject_1$k || (templateObject_1$k = __makeTemplateObject(["\n background-color: ", ";\n"], ["\n background-color: ", ";\n"])), function (props) { return props.theme.palette.kale["100"]; });
|
|
1380
|
-
var UgNavItem$2 = styled__default["default"](reactChrome.NavItem)(templateObject_2$
|
|
1391
|
+
var UgNavItem$2 = styled__default["default"](reactChrome.NavItem)(templateObject_2$a || (templateObject_2$a = __makeTemplateObject(["\n border-top-left-radius: ", "px;\n border-bottom-left-radius: ", "px;\n font-family: ", ";\n ", "\n ", "\n &:hover, &:focus {\n ", "\n }\n opacity: 1;\n color: ", ";\n font-weight: ", ";\n ", "\n"], ["\n border-top-left-radius: ", "px;\n border-bottom-left-radius: ", "px;\n font-family: ", ";\n ", "\n ", "\n &:hover, &:focus {\n ", "\n }\n opacity: 1;\n color: ", ";\n font-weight: ", ";\n ", "\n"])), function (props) { return props.theme.space.base * 6; }, function (props) { return props.theme.space.base * 6; }, function (_a) {
|
|
1381
1392
|
var theme = _a.theme;
|
|
1382
1393
|
return theme.fonts.system;
|
|
1383
1394
|
}, function (props) { return !props.isExpanded && "display: none;"; }, function (props) { return props.isCurrent && SelectedItemStyle; }, SelectedItemStyle, function (props) { return props.theme.palette.blue["600"]; }, function (props) { return props.theme.fontWeights.medium; }, function (props) {
|
|
@@ -1388,7 +1399,7 @@ var NavItem = function (props) {
|
|
|
1388
1399
|
// const { isExpanded } = props;
|
|
1389
1400
|
return jsxRuntime.jsx(UgNavItem$2, __assign({}, props));
|
|
1390
1401
|
};
|
|
1391
|
-
var templateObject_1$k, templateObject_2$
|
|
1402
|
+
var templateObject_1$k, templateObject_2$a;
|
|
1392
1403
|
|
|
1393
1404
|
var UgNavIcon = styled__default["default"](reactChrome.NavItemIcon)(templateObject_1$j || (templateObject_1$j = __makeTemplateObject([""], [""])));
|
|
1394
1405
|
var NavItemIcon = function (props) { return jsxRuntime.jsx(UgNavIcon, __assign({}, props)); };
|
|
@@ -1450,11 +1461,11 @@ var NavDivider = function (props) { return (jsxRuntime.jsx(UgNavItem$1, __assign
|
|
|
1450
1461
|
var templateObject_1$h;
|
|
1451
1462
|
|
|
1452
1463
|
var UgProjectSubtitle = styled__default["default"](NavItemText)(templateObject_1$g || (templateObject_1$g = __makeTemplateObject(["\n color: ", ";\n font-size: ", ";\n"], ["\n color: ", ";\n font-size: ", ";\n"])), function (props) { return props.theme.palette.grey["500"]; }, function (props) { return props.theme.fontSizes.sm; });
|
|
1453
|
-
var UgNavItem = styled__default["default"](NavItem)(templateObject_2$
|
|
1464
|
+
var UgNavItem = styled__default["default"](NavItem)(templateObject_2$9 || (templateObject_2$9 = __makeTemplateObject(["\n flex-flow: column;\n align-items: flex-start;\n"], ["\n flex-flow: column;\n align-items: flex-start;\n"])));
|
|
1454
1465
|
var NavItemProject = function (props) { return jsxRuntime.jsx(UgNavItem, __assign({}, props)); };
|
|
1455
1466
|
NavItemProject.Title = NavItemText;
|
|
1456
1467
|
NavItemProject.SubTitle = UgProjectSubtitle;
|
|
1457
|
-
var templateObject_1$g, templateObject_2$
|
|
1468
|
+
var templateObject_1$g, templateObject_2$9;
|
|
1458
1469
|
|
|
1459
1470
|
var _path$8;
|
|
1460
1471
|
|
|
@@ -1553,6 +1564,7 @@ var SvgToken = function SvgToken(props) {
|
|
|
1553
1564
|
var Span = function (props) { return jsxRuntime.jsx(reactTypography.Span, __assign({}, props)); };
|
|
1554
1565
|
|
|
1555
1566
|
var TokenContainer = styled__default["default"].div(templateObject_1$f || (templateObject_1$f = __makeTemplateObject(["\n display: flex;\n align-items: center;\n justify-content: center;\n"], ["\n display: flex;\n align-items: center;\n justify-content: center;\n"])));
|
|
1567
|
+
var ScrollingContainer = styled__default["default"].div(templateObject_2$8 || (templateObject_2$8 = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n order: 1;\n overflow-y: auto;\n height: 100%;\n"], ["\n display: flex;\n flex-direction: column;\n order: 1;\n overflow-y: auto;\n height: 100%;\n"])));
|
|
1556
1568
|
/**
|
|
1557
1569
|
* The UNGUESS Sidebar component provides a high-level layout structure and sets a framework for navigating around projects.
|
|
1558
1570
|
* <br>
|
|
@@ -1568,10 +1580,10 @@ var Sidebar = function (props) {
|
|
|
1568
1580
|
props.onNavToggle && props.onNavToggle(route);
|
|
1569
1581
|
setNav(route);
|
|
1570
1582
|
};
|
|
1571
|
-
return (jsxRuntime.jsxs(Nav, __assign({}, props, { children: [jsxRuntime.jsx(NavToggle, { onClick: toggleNav, isExpanded: props.isExpanded }), props.tokens && (jsxRuntime.jsx(NavItem, __assign({ hasLogo: true, isExpanded: props.isExpanded, style: { pointerEvents: "none", paddingTop: 0 } }, { children: jsxRuntime.jsx(Card, __assign({ style: { padding: theme.space.sm, width: "70%" } }, { children: jsxRuntime.jsxs(TokenContainer, { children: [jsxRuntime.jsx(SvgToken, { width: 32 }), jsxRuntime.jsx(Span, __assign({ isBold: true, style: { marginLeft: theme.space.xs } }, { children: props.tokens + " " + (props.tokensLabel || "tokens") }))] }) })) }))), jsxRuntime.jsxs(NavItem, __assign({ isExpanded: props.isExpanded, isCurrent: nav === "home", onClick: function () { return navigate("home"); } }, { children: [jsxRuntime.jsx(NavItemIcon, __assign({ isStyled: true }, { children: nav === "home" ? jsxRuntime.jsx(SvgHomeFillStyled, {}) : jsxRuntime.jsx(SvgHomeFill, {}) })), jsxRuntime.jsx(NavItemText, { children: props.homeItemLabel || "My Campaigns" })] })), jsxRuntime.jsx(NavDivider, __assign({ isExpanded: props.isExpanded }, { children: props.dividerLabel || "" })), props.projects &&
|
|
1572
|
-
|
|
1583
|
+
return (jsxRuntime.jsxs(Nav, __assign({}, props, { children: [jsxRuntime.jsx(NavToggle, { onClick: toggleNav, isExpanded: props.isExpanded }), props.tokens && (jsxRuntime.jsx(NavItem, __assign({ hasLogo: true, isExpanded: props.isExpanded, style: { pointerEvents: "none", paddingTop: 0 } }, { children: jsxRuntime.jsx(Card, __assign({ style: { padding: theme.space.sm, width: "70%" } }, { children: jsxRuntime.jsxs(TokenContainer, { children: [jsxRuntime.jsx(SvgToken, { width: 32 }), jsxRuntime.jsx(Span, __assign({ isBold: true, style: { marginLeft: theme.space.xs } }, { children: props.tokens + " " + (props.tokensLabel || "tokens") }))] }) })) }))), jsxRuntime.jsxs(NavItem, __assign({ isExpanded: props.isExpanded, isCurrent: nav === "home", onClick: function () { return navigate("home"); } }, { children: [jsxRuntime.jsx(NavItemIcon, __assign({ isStyled: true }, { children: nav === "home" ? jsxRuntime.jsx(SvgHomeFillStyled, {}) : jsxRuntime.jsx(SvgHomeFill, {}) })), jsxRuntime.jsx(NavItemText, { children: props.homeItemLabel || "My Campaigns" })] })), jsxRuntime.jsx(NavDivider, __assign({ isExpanded: props.isExpanded }, { children: props.dividerLabel || "" })), jsxRuntime.jsx(ScrollingContainer, { children: props.projects &&
|
|
1584
|
+
props.projects.map(function (project) { return (jsxRuntime.jsxs(NavItemProject, __assign({ isExpanded: props.isExpanded, isCurrent: nav === project.id, onClick: function () { return navigate(project.id); } }, { children: [jsxRuntime.jsx(NavItemProject.Title, { title: project.title, children: project.title }), jsxRuntime.jsx(NavItemProject.SubTitle, { children: project.campaigns })] }), project.id)); }) }), jsxRuntime.jsxs(NavItem, __assign({ isExpanded: props.isExpanded, hasBrandmark: true, title: "Be smart from the start", style: { pointerEvents: "none" } }, { children: [jsxRuntime.jsx(NavItemIcon, { children: jsxRuntime.jsx(Logo, { type: "icon", size: 150 }) }), jsxRuntime.jsx(NavItemText, { children: "UNGUESS" })] }))] })));
|
|
1573
1585
|
};
|
|
1574
|
-
var templateObject_1$f;
|
|
1586
|
+
var templateObject_1$f, templateObject_2$8;
|
|
1575
1587
|
|
|
1576
1588
|
/**
|
|
1577
1589
|
* The Chrome component provides a high-level layout structure and sets a framework for navigating around Zendesk products.
|
|
@@ -2105,6 +2117,7 @@ exports.MD = MD;
|
|
|
2105
2117
|
exports.Main = Main;
|
|
2106
2118
|
exports.MediaBody = MediaBody;
|
|
2107
2119
|
exports.MediaFigure = MediaFigure;
|
|
2120
|
+
exports.MediaInput = MediaInput;
|
|
2108
2121
|
exports.MediaItem = MediaItem;
|
|
2109
2122
|
exports.Menu = Menu;
|
|
2110
2123
|
exports.Message = Message;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { IMediaInputProps } from "@zendeskgarden/react-forms";
|
|
2
|
+
export interface MediaInputArgs extends IMediaInputProps {
|
|
3
|
+
/** Applies compact styling */
|
|
4
|
+
isCompact?: boolean;
|
|
5
|
+
/** Removes borders and padding */
|
|
6
|
+
isBare?: boolean;
|
|
7
|
+
/** Accepts a "start" icon to display */
|
|
8
|
+
start?: any;
|
|
9
|
+
/** Accepts an "end" icon to display */
|
|
10
|
+
end?: any;
|
|
11
|
+
/** Applies validation state styling */
|
|
12
|
+
validation?: 'success' | 'warning' | 'error';
|
|
13
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { MediaInputArgs } from "./_types";
|
|
3
|
+
/**
|
|
4
|
+
* Media elements add even more context to an input.
|
|
5
|
+
* <hr>
|
|
6
|
+
* Used for this:
|
|
7
|
+
* - To let the user enter data into a field
|
|
8
|
+
* - To enter multiline text, use a Textarea
|
|
9
|
+
**/
|
|
10
|
+
declare const MediaInput: (props: MediaInputArgs) => JSX.Element;
|
|
11
|
+
export { MediaInput };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { ComponentMeta, Story } from "@storybook/react";
|
|
3
|
+
import { MediaInputArgs } from "./_types";
|
|
4
|
+
export declare const Default: Story<MediaInputArgs>;
|
|
5
|
+
export declare const Success: Story<MediaInputArgs>;
|
|
6
|
+
export declare const Warning: Story<MediaInputArgs>;
|
|
7
|
+
export declare const Error: Story<MediaInputArgs>;
|
|
8
|
+
declare const _default: ComponentMeta<(props: MediaInputArgs) => JSX.Element>;
|
|
9
|
+
export default _default;
|