@plurid/plurid-ui-components-react 0.0.0-15 → 0.0.0-16
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 +37 -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/index.es.js +145 -1
- package/distribution/index.es.js.map +1 -1
- package/distribution/index.js +145 -1
- package/distribution/index.js.map +1 -1
- package/package.json +18 -18
package/distribution/index.js
CHANGED
|
@@ -2585,6 +2585,149 @@ const universal = {
|
|
|
2585
2585
|
varia: varia
|
|
2586
2586
|
};
|
|
2587
2587
|
|
|
2588
|
+
const Head = properties => {
|
|
2589
|
+
var _a, _b, _c, _d;
|
|
2590
|
+
const {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(React__default["default"].Fragment, 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("meta", {
|
|
2620
|
+
name: "description",
|
|
2621
|
+
content: descriptionValue
|
|
2622
|
+
}), React__default["default"].createElement("title", null, titleValue), React__default["default"].createElement("meta", {
|
|
2623
|
+
name: "title",
|
|
2624
|
+
content: titleValue
|
|
2625
|
+
}), React__default["default"].createElement("meta", {
|
|
2626
|
+
name: "description",
|
|
2627
|
+
content: descriptionValue
|
|
2628
|
+
}), apiDomain && React__default["default"].createElement(React__default["default"].Fragment, null, React__default["default"].createElement("link", {
|
|
2629
|
+
rel: "preconnect",
|
|
2630
|
+
href: apiDomain
|
|
2631
|
+
}), React__default["default"].createElement("link", {
|
|
2632
|
+
rel: "dns-prefetch",
|
|
2633
|
+
href: apiDomain
|
|
2634
|
+
})), faviconIcon && React__default["default"].createElement("link", {
|
|
2635
|
+
rel: "icon",
|
|
2636
|
+
sizes: "64x64",
|
|
2637
|
+
href: faviconIcon
|
|
2638
|
+
}), favicon32 && React__default["default"].createElement("link", {
|
|
2639
|
+
rel: "icon",
|
|
2640
|
+
type: "image/png",
|
|
2641
|
+
sizes: "32x32",
|
|
2642
|
+
href: favicon32
|
|
2643
|
+
}), favicon16 && React__default["default"].createElement("link", {
|
|
2644
|
+
rel: "icon",
|
|
2645
|
+
type: "image/png",
|
|
2646
|
+
sizes: "16x16",
|
|
2647
|
+
href: favicon16
|
|
2648
|
+
}), manifest && React__default["default"].createElement("link", {
|
|
2649
|
+
rel: "manifest",
|
|
2650
|
+
href: manifest
|
|
2651
|
+
}), themeColor && React__default["default"].createElement("meta", {
|
|
2652
|
+
name: "theme-color",
|
|
2653
|
+
content: themeColor
|
|
2654
|
+
}), canonicalURL && React__default["default"].createElement("link", {
|
|
2655
|
+
rel: "canonical",
|
|
2656
|
+
href: canonicalURL
|
|
2657
|
+
}), React__default["default"].createElement("meta", {
|
|
2658
|
+
property: "og:type",
|
|
2659
|
+
content: "website"
|
|
2660
|
+
}), React__default["default"].createElement("meta", {
|
|
2661
|
+
property: "og:title",
|
|
2662
|
+
content: ogTitleValue
|
|
2663
|
+
}), React__default["default"].createElement("meta", {
|
|
2664
|
+
property: "og:image",
|
|
2665
|
+
content: ogImageValue
|
|
2666
|
+
}), React__default["default"].createElement("meta", {
|
|
2667
|
+
property: "og:image:width",
|
|
2668
|
+
content: ogImageWidth
|
|
2669
|
+
}), React__default["default"].createElement("meta", {
|
|
2670
|
+
property: "og:image:height",
|
|
2671
|
+
content: ogImageHeight
|
|
2672
|
+
}), ogSiteName && React__default["default"].createElement("meta", {
|
|
2673
|
+
property: "og:site_name",
|
|
2674
|
+
content: ogSiteName
|
|
2675
|
+
}), React__default["default"].createElement("meta", {
|
|
2676
|
+
property: "og:url",
|
|
2677
|
+
content: ogURLValue
|
|
2678
|
+
}), React__default["default"].createElement("meta", {
|
|
2679
|
+
property: "og:description",
|
|
2680
|
+
content: ogDescriptionValue
|
|
2681
|
+
}), React__default["default"].createElement("meta", {
|
|
2682
|
+
property: "twitter:card",
|
|
2683
|
+
content: "summary_large_image"
|
|
2684
|
+
}), React__default["default"].createElement("meta", {
|
|
2685
|
+
property: "twitter:url",
|
|
2686
|
+
content: ogURLValue
|
|
2687
|
+
}), React__default["default"].createElement("meta", {
|
|
2688
|
+
property: "twitter:title",
|
|
2689
|
+
content: ogTitleValue
|
|
2690
|
+
}), React__default["default"].createElement("meta", {
|
|
2691
|
+
property: "twitter:description",
|
|
2692
|
+
content: ogDescriptionValue
|
|
2693
|
+
}), React__default["default"].createElement("meta", {
|
|
2694
|
+
property: "twitter:image",
|
|
2695
|
+
content: ogImageValue
|
|
2696
|
+
}), React__default["default"].createElement("meta", {
|
|
2697
|
+
name: "apple-mobile-web-app-capable",
|
|
2698
|
+
content: "yes"
|
|
2699
|
+
}), React__default["default"].createElement("meta", {
|
|
2700
|
+
name: "apple-mobile-web-app-status-bar-style",
|
|
2701
|
+
content: "default"
|
|
2702
|
+
}), React__default["default"].createElement("meta", {
|
|
2703
|
+
name: "apple-mobile-web-app-title",
|
|
2704
|
+
content: titleValue
|
|
2705
|
+
}), appleTouchIcon && React__default["default"].createElement("link", {
|
|
2706
|
+
rel: "apple-touch-icon",
|
|
2707
|
+
sizes: "180x180",
|
|
2708
|
+
href: appleTouchIcon
|
|
2709
|
+
}), children, styles === null || styles === void 0 ? void 0 : styles.map((style => React__default["default"].createElement("link", {
|
|
2710
|
+
rel: "stylesheet",
|
|
2711
|
+
key: "head-style" + style,
|
|
2712
|
+
href: style
|
|
2713
|
+
}))), scripts === null || scripts === void 0 ? void 0 : scripts.map((script => React__default["default"].createElement("script", {
|
|
2714
|
+
key: "head-script" + script,
|
|
2715
|
+
src: script
|
|
2716
|
+
}))));
|
|
2717
|
+
};
|
|
2718
|
+
|
|
2719
|
+
const mapStateToProperties$7 = (state, ownProperties) => ({
|
|
2720
|
+
stateHead: ownProperties.selectors.notifications.getAll(state)
|
|
2721
|
+
});
|
|
2722
|
+
|
|
2723
|
+
const mapDispatchToProperties$7 = dispatch => ({});
|
|
2724
|
+
|
|
2725
|
+
const ConnectedHead = reactRedux.connect(mapStateToProperties$7, mapDispatchToProperties$7)(Head);
|
|
2726
|
+
|
|
2727
|
+
const head = {
|
|
2728
|
+
Head: ConnectedHead
|
|
2729
|
+
};
|
|
2730
|
+
|
|
2588
2731
|
const translateUp = styled.keyframes`
|
|
2589
2732
|
from {
|
|
2590
2733
|
transform: translateY(2000px);
|
|
@@ -2702,7 +2845,7 @@ const mapStateToProperties$6 = (state, ownProperties) => ({
|
|
|
2702
2845
|
});
|
|
2703
2846
|
|
|
2704
2847
|
const mapDispatchToProperties$6 = dispatch => ({
|
|
2705
|
-
dispatchRemoveNotification: payload => dispatch(pluridUiStateReact.notifications.actions.
|
|
2848
|
+
dispatchRemoveNotification: payload => dispatch(pluridUiStateReact.notifications.actions.remove(payload))
|
|
2706
2849
|
});
|
|
2707
2850
|
|
|
2708
2851
|
const ConnectedNotifications = reactRedux.connect(mapStateToProperties$6, mapDispatchToProperties$6)(Notifications);
|
|
@@ -3572,6 +3715,7 @@ const toolbars = {
|
|
|
3572
3715
|
};
|
|
3573
3716
|
|
|
3574
3717
|
const pluridal = {
|
|
3718
|
+
head: head,
|
|
3575
3719
|
notifications: notifications,
|
|
3576
3720
|
sitting: sitting,
|
|
3577
3721
|
toolbars: toolbars
|