@plurid/plurid-ui-components-react 0.0.0-15 → 0.0.0-18
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/distribution/components/pluridal/head/Head/index.d.ts +38 -0
- package/distribution/components/pluridal/head/index.d.ts +5 -0
- package/distribution/components/pluridal/index.d.ts +3 -0
- package/distribution/components/pluridal/notifications/Notification/index.d.ts +1 -1
- package/distribution/components/pluridal/notifications/Notifications/index.d.ts +1 -1
- package/distribution/components/universal/inputs/InputSwitch/index.d.ts +2 -0
- package/distribution/index.es.js +145 -4
- package/distribution/index.es.js.map +1 -1
- package/distribution/index.js +145 -4
- package/distribution/index.js.map +1 -1
- package/package.json +21 -21
package/distribution/index.js
CHANGED
|
@@ -1799,7 +1799,7 @@ const StyledInputSwitch = styled__default["default"].div`
|
|
|
1799
1799
|
`;
|
|
1800
1800
|
|
|
1801
1801
|
const InputSwitch = properties => {
|
|
1802
|
-
const {name: name, checked: checked, atChange: atChange, theme: themeProperty, compact: compact, style: style, className: className} = properties;
|
|
1802
|
+
const {name: name, checked: checked, atChange: atChange, theme: themeProperty, compact: compact, switch: switchProperties, style: style, className: className} = properties;
|
|
1803
1803
|
const theme = themeProperty || themes.plurid;
|
|
1804
1804
|
return React__default["default"].createElement(StyledInputSwitch, {
|
|
1805
1805
|
compact: compact,
|
|
@@ -1809,13 +1809,13 @@ const InputSwitch = properties => {
|
|
|
1809
1809
|
style: {
|
|
1810
1810
|
marginLeft: "0.9rem"
|
|
1811
1811
|
}
|
|
1812
|
-
}, name), React__default["default"].createElement(Switch, {
|
|
1812
|
+
}, name), React__default["default"].createElement(Switch, Object.assign({
|
|
1813
1813
|
checked: checked,
|
|
1814
1814
|
level: 2,
|
|
1815
1815
|
exclusive: true,
|
|
1816
1816
|
theme: theme,
|
|
1817
1817
|
atChange: () => atChange()
|
|
1818
|
-
})));
|
|
1818
|
+
}, switchProperties))));
|
|
1819
1819
|
};
|
|
1820
1820
|
|
|
1821
1821
|
const StyledItemsline = styled__default["default"].div`
|
|
@@ -2585,6 +2585,146 @@ const universal = {
|
|
|
2585
2585
|
varia: varia
|
|
2586
2586
|
};
|
|
2587
2587
|
|
|
2588
|
+
const Head = properties => {
|
|
2589
|
+
var _a, _b, _c, _d;
|
|
2590
|
+
const {Helmet: Helmet, defaults: defaults, children: children, stateHead: stateHead} = properties;
|
|
2591
|
+
const robots = (defaults === null || defaults === void 0 ? void 0 : defaults.robots) || "index,follow";
|
|
2592
|
+
const viewport = (defaults === null || defaults === void 0 ? void 0 : defaults.viewport) || "width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0, shrink-to-fit=no";
|
|
2593
|
+
const faviconIcon = (_a = defaults === null || defaults === void 0 ? void 0 : defaults.faviconIcon) !== null && _a !== void 0 ? _a : "/favicon.ico";
|
|
2594
|
+
const favicon16 = (_b = defaults === null || defaults === void 0 ? void 0 : defaults.favicon16) !== null && _b !== void 0 ? _b : "/favicon-32x32.png";
|
|
2595
|
+
const favicon32 = (_c = defaults === null || defaults === void 0 ? void 0 : defaults.favicon32) !== null && _c !== void 0 ? _c : "/favicon-16x16.png";
|
|
2596
|
+
const manifest = (_d = defaults === null || defaults === void 0 ? void 0 : defaults.manifest) !== null && _d !== void 0 ? _d : "/site.webmanifest";
|
|
2597
|
+
const themeColor = (defaults === null || defaults === void 0 ? void 0 : defaults.themeColor) || "";
|
|
2598
|
+
const titleValue = stateHead.title || (defaults === null || defaults === void 0 ? void 0 : defaults.title) || "";
|
|
2599
|
+
const descriptionValue = stateHead.description || (defaults === null || defaults === void 0 ? void 0 : defaults.description) || "";
|
|
2600
|
+
const canonicalURL = stateHead.canonicalURL || (defaults === null || defaults === void 0 ? void 0 : defaults.canonicalURL) || "";
|
|
2601
|
+
const ogTitleValue = stateHead.ogTitle || titleValue;
|
|
2602
|
+
const ogDescriptionValue = stateHead.ogDescription || titleValue;
|
|
2603
|
+
const ogImageValue = stateHead.ogImage || (defaults === null || defaults === void 0 ? void 0 : defaults.ogImage) || "";
|
|
2604
|
+
const ogURLValue = stateHead.ogURL || (defaults === null || defaults === void 0 ? void 0 : defaults.ogURL) || "";
|
|
2605
|
+
const apiDomain = (defaults === null || defaults === void 0 ? void 0 : defaults.apiDomain) || "";
|
|
2606
|
+
const ogImageWidth = (defaults === null || defaults === void 0 ? void 0 : defaults.ogImageWidth) || "1200";
|
|
2607
|
+
const ogImageHeight = (defaults === null || defaults === void 0 ? void 0 : defaults.ogImageHeight) || "630";
|
|
2608
|
+
const ogSiteName = (defaults === null || defaults === void 0 ? void 0 : defaults.ogSiteName) || "";
|
|
2609
|
+
const appleTouchIcon = (defaults === null || defaults === void 0 ? void 0 : defaults.appleTouchIcon) || "";
|
|
2610
|
+
const {styles: styles, scripts: scripts} = stateHead;
|
|
2611
|
+
return React__default["default"].createElement(Helmet, null, React__default["default"].createElement("meta", {
|
|
2612
|
+
charSet: "utf-8"
|
|
2613
|
+
}), React__default["default"].createElement("meta", {
|
|
2614
|
+
name: "robots",
|
|
2615
|
+
content: robots
|
|
2616
|
+
}), React__default["default"].createElement("meta", {
|
|
2617
|
+
name: "viewport",
|
|
2618
|
+
content: viewport
|
|
2619
|
+
}), React__default["default"].createElement("title", null, titleValue), React__default["default"].createElement("meta", {
|
|
2620
|
+
name: "title",
|
|
2621
|
+
content: titleValue
|
|
2622
|
+
}), React__default["default"].createElement("meta", {
|
|
2623
|
+
name: "description",
|
|
2624
|
+
content: descriptionValue
|
|
2625
|
+
}), apiDomain && React__default["default"].createElement(React__default["default"].Fragment, null, React__default["default"].createElement("link", {
|
|
2626
|
+
rel: "preconnect",
|
|
2627
|
+
href: apiDomain
|
|
2628
|
+
}), React__default["default"].createElement("link", {
|
|
2629
|
+
rel: "dns-prefetch",
|
|
2630
|
+
href: apiDomain
|
|
2631
|
+
})), faviconIcon && React__default["default"].createElement("link", {
|
|
2632
|
+
rel: "icon",
|
|
2633
|
+
sizes: "64x64",
|
|
2634
|
+
href: faviconIcon
|
|
2635
|
+
}), favicon32 && React__default["default"].createElement("link", {
|
|
2636
|
+
rel: "icon",
|
|
2637
|
+
type: "image/png",
|
|
2638
|
+
sizes: "32x32",
|
|
2639
|
+
href: favicon32
|
|
2640
|
+
}), favicon16 && React__default["default"].createElement("link", {
|
|
2641
|
+
rel: "icon",
|
|
2642
|
+
type: "image/png",
|
|
2643
|
+
sizes: "16x16",
|
|
2644
|
+
href: favicon16
|
|
2645
|
+
}), manifest && React__default["default"].createElement("link", {
|
|
2646
|
+
rel: "manifest",
|
|
2647
|
+
href: manifest
|
|
2648
|
+
}), themeColor && React__default["default"].createElement("meta", {
|
|
2649
|
+
name: "theme-color",
|
|
2650
|
+
content: themeColor
|
|
2651
|
+
}), canonicalURL && React__default["default"].createElement("link", {
|
|
2652
|
+
rel: "canonical",
|
|
2653
|
+
href: canonicalURL
|
|
2654
|
+
}), React__default["default"].createElement("meta", {
|
|
2655
|
+
property: "og:type",
|
|
2656
|
+
content: "website"
|
|
2657
|
+
}), React__default["default"].createElement("meta", {
|
|
2658
|
+
property: "og:title",
|
|
2659
|
+
content: ogTitleValue
|
|
2660
|
+
}), React__default["default"].createElement("meta", {
|
|
2661
|
+
property: "og:image",
|
|
2662
|
+
content: ogImageValue
|
|
2663
|
+
}), React__default["default"].createElement("meta", {
|
|
2664
|
+
property: "og:image:width",
|
|
2665
|
+
content: ogImageWidth
|
|
2666
|
+
}), React__default["default"].createElement("meta", {
|
|
2667
|
+
property: "og:image:height",
|
|
2668
|
+
content: ogImageHeight
|
|
2669
|
+
}), ogSiteName && React__default["default"].createElement("meta", {
|
|
2670
|
+
property: "og:site_name",
|
|
2671
|
+
content: ogSiteName
|
|
2672
|
+
}), React__default["default"].createElement("meta", {
|
|
2673
|
+
property: "og:url",
|
|
2674
|
+
content: ogURLValue
|
|
2675
|
+
}), React__default["default"].createElement("meta", {
|
|
2676
|
+
property: "og:description",
|
|
2677
|
+
content: ogDescriptionValue
|
|
2678
|
+
}), React__default["default"].createElement("meta", {
|
|
2679
|
+
property: "twitter:card",
|
|
2680
|
+
content: "summary_large_image"
|
|
2681
|
+
}), React__default["default"].createElement("meta", {
|
|
2682
|
+
property: "twitter:url",
|
|
2683
|
+
content: ogURLValue
|
|
2684
|
+
}), React__default["default"].createElement("meta", {
|
|
2685
|
+
property: "twitter:title",
|
|
2686
|
+
content: ogTitleValue
|
|
2687
|
+
}), React__default["default"].createElement("meta", {
|
|
2688
|
+
property: "twitter:description",
|
|
2689
|
+
content: ogDescriptionValue
|
|
2690
|
+
}), React__default["default"].createElement("meta", {
|
|
2691
|
+
property: "twitter:image",
|
|
2692
|
+
content: ogImageValue
|
|
2693
|
+
}), React__default["default"].createElement("meta", {
|
|
2694
|
+
name: "apple-mobile-web-app-capable",
|
|
2695
|
+
content: "yes"
|
|
2696
|
+
}), React__default["default"].createElement("meta", {
|
|
2697
|
+
name: "apple-mobile-web-app-status-bar-style",
|
|
2698
|
+
content: "default"
|
|
2699
|
+
}), React__default["default"].createElement("meta", {
|
|
2700
|
+
name: "apple-mobile-web-app-title",
|
|
2701
|
+
content: titleValue
|
|
2702
|
+
}), appleTouchIcon && React__default["default"].createElement("link", {
|
|
2703
|
+
rel: "apple-touch-icon",
|
|
2704
|
+
sizes: "180x180",
|
|
2705
|
+
href: appleTouchIcon
|
|
2706
|
+
}), children, styles === null || styles === void 0 ? void 0 : styles.map((style => React__default["default"].createElement("link", {
|
|
2707
|
+
rel: "stylesheet",
|
|
2708
|
+
key: "head-style" + style,
|
|
2709
|
+
href: style
|
|
2710
|
+
}))), scripts === null || scripts === void 0 ? void 0 : scripts.map((script => React__default["default"].createElement("script", {
|
|
2711
|
+
key: "head-script" + script,
|
|
2712
|
+
src: script
|
|
2713
|
+
}))));
|
|
2714
|
+
};
|
|
2715
|
+
|
|
2716
|
+
const mapStateToProperties$7 = (state, ownProperties) => ({
|
|
2717
|
+
stateHead: ownProperties.selectors.head.getHead(state)
|
|
2718
|
+
});
|
|
2719
|
+
|
|
2720
|
+
const mapDispatchToProperties$7 = dispatch => ({});
|
|
2721
|
+
|
|
2722
|
+
const ConnectedHead = reactRedux.connect(mapStateToProperties$7, mapDispatchToProperties$7)(Head);
|
|
2723
|
+
|
|
2724
|
+
const head = {
|
|
2725
|
+
Head: ConnectedHead
|
|
2726
|
+
};
|
|
2727
|
+
|
|
2588
2728
|
const translateUp = styled.keyframes`
|
|
2589
2729
|
from {
|
|
2590
2730
|
transform: translateY(2000px);
|
|
@@ -2702,7 +2842,7 @@ const mapStateToProperties$6 = (state, ownProperties) => ({
|
|
|
2702
2842
|
});
|
|
2703
2843
|
|
|
2704
2844
|
const mapDispatchToProperties$6 = dispatch => ({
|
|
2705
|
-
dispatchRemoveNotification: payload => dispatch(pluridUiStateReact.notifications.actions.
|
|
2845
|
+
dispatchRemoveNotification: payload => dispatch(pluridUiStateReact.notifications.actions.remove(payload))
|
|
2706
2846
|
});
|
|
2707
2847
|
|
|
2708
2848
|
const ConnectedNotifications = reactRedux.connect(mapStateToProperties$6, mapDispatchToProperties$6)(Notifications);
|
|
@@ -3572,6 +3712,7 @@ const toolbars = {
|
|
|
3572
3712
|
};
|
|
3573
3713
|
|
|
3574
3714
|
const pluridal = {
|
|
3715
|
+
head: head,
|
|
3575
3716
|
notifications: notifications,
|
|
3576
3717
|
sitting: sitting,
|
|
3577
3718
|
toolbars: toolbars
|