react-better-html 1.1.291 → 1.1.292
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/index.d.mts +22 -7
- package/dist/index.d.ts +22 -7
- package/dist/index.js +93 -24
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +70 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/index.ts
|
|
2
2
|
import {
|
|
3
|
-
useTheme as
|
|
3
|
+
useTheme as useTheme31,
|
|
4
4
|
useLoader as useLoader2,
|
|
5
5
|
useLoaderControls,
|
|
6
6
|
countries as countries3,
|
|
@@ -8767,11 +8767,79 @@ var SideMenu2 = memo27(SideMenuComponent);
|
|
|
8767
8767
|
SideMenu2.pageHolder = SideMenuComponent.pageHolder;
|
|
8768
8768
|
SideMenu2.burgerButton = SideMenuComponent.burgerButton;
|
|
8769
8769
|
var SideMenu_default = SideMenu2;
|
|
8770
|
+
|
|
8771
|
+
// src/components/DeveloperPage.tsx
|
|
8772
|
+
import { memo as memo28 } from "react";
|
|
8773
|
+
import { useBetterCoreContext as useBetterCoreContext11, useTheme as useTheme30 } from "react-better-core";
|
|
8774
|
+
import { jsx as jsx29, jsxs as jsxs25 } from "react/jsx-runtime";
|
|
8775
|
+
function DeveloperPage({ iconSize = 24, assetSize = 120, sections }) {
|
|
8776
|
+
const theme2 = useTheme30();
|
|
8777
|
+
const { devMode, icons: icons2, assets: assets2 } = useBetterCoreContext11();
|
|
8778
|
+
const gridGap = theme2.styles.space;
|
|
8779
|
+
const iconNameFontSie = 12;
|
|
8780
|
+
return devMode ? /* @__PURE__ */ jsxs25(Div_default.column, { gap: theme2.styles.space, children: [
|
|
8781
|
+
/* @__PURE__ */ jsx29(Div_default.box, { title: "Icons", titleAs: "h2", description: "List of all icons in the config", children: /* @__PURE__ */ jsx29(Div_default.row, { alignItems: "center", justifyContent: "center", flexWrap: "wrap", gap: gridGap, children: Object.keys(icons2).map((icon) => /* @__PURE__ */ jsxs25(
|
|
8782
|
+
Div_default.row,
|
|
8783
|
+
{
|
|
8784
|
+
position: "relative",
|
|
8785
|
+
width: iconSize + gridGap * 2 + iconNameFontSie,
|
|
8786
|
+
height: iconSize + gridGap * 2 + iconNameFontSie,
|
|
8787
|
+
alignItems: "center",
|
|
8788
|
+
justifyContent: "center",
|
|
8789
|
+
children: [
|
|
8790
|
+
/* @__PURE__ */ jsx29(Icon_default, { name: icon, color: theme2.colors.primary, size: iconSize }),
|
|
8791
|
+
/* @__PURE__ */ jsx29(
|
|
8792
|
+
Text_default,
|
|
8793
|
+
{
|
|
8794
|
+
position: "absolute",
|
|
8795
|
+
width: "100%",
|
|
8796
|
+
top: `calc(100% - ${iconNameFontSie}px)`,
|
|
8797
|
+
fontSize: iconNameFontSie,
|
|
8798
|
+
textAlign: "center",
|
|
8799
|
+
wordBreak: "break-all",
|
|
8800
|
+
color: theme2.colors.textSecondary,
|
|
8801
|
+
children: icon
|
|
8802
|
+
}
|
|
8803
|
+
)
|
|
8804
|
+
]
|
|
8805
|
+
},
|
|
8806
|
+
icon
|
|
8807
|
+
)) }) }),
|
|
8808
|
+
/* @__PURE__ */ jsx29(Div_default.box, { title: "Assets", titleAs: "h2", description: "List of all assets in the config", children: /* @__PURE__ */ jsx29(Div_default.row, { alignItems: "center", justifyContent: "center", flexWrap: "wrap", gap: gridGap, children: Object.keys(assets2).map((asset) => /* @__PURE__ */ jsxs25(
|
|
8809
|
+
Div_default.column,
|
|
8810
|
+
{
|
|
8811
|
+
position: "relative",
|
|
8812
|
+
width: assetSize,
|
|
8813
|
+
alignItems: "center",
|
|
8814
|
+
justifyContent: "center",
|
|
8815
|
+
gap: theme2.styles.gap,
|
|
8816
|
+
children: [
|
|
8817
|
+
/* @__PURE__ */ jsx29(Image_default, { name: asset, width: "100%", height: assetSize, objectFit: "contain" }),
|
|
8818
|
+
/* @__PURE__ */ jsx29(
|
|
8819
|
+
Text_default,
|
|
8820
|
+
{
|
|
8821
|
+
width: "100%",
|
|
8822
|
+
fontSize: iconNameFontSie,
|
|
8823
|
+
textAlign: "center",
|
|
8824
|
+
wordBreak: "break-all",
|
|
8825
|
+
color: theme2.colors.textSecondary,
|
|
8826
|
+
children: asset
|
|
8827
|
+
}
|
|
8828
|
+
)
|
|
8829
|
+
]
|
|
8830
|
+
},
|
|
8831
|
+
asset
|
|
8832
|
+
)) }) }),
|
|
8833
|
+
sections?.map((section) => /* @__PURE__ */ jsx29(Div_default.box, { title: section.title, titleAs: "h2", description: section.description, children: section.children }, section.title))
|
|
8834
|
+
] }) : void 0;
|
|
8835
|
+
}
|
|
8836
|
+
var DeveloperPage_default = memo28(DeveloperPage);
|
|
8770
8837
|
export {
|
|
8771
8838
|
BetterHtmlProvider_default as BetterHtmlProvider,
|
|
8772
8839
|
Button_default as Button,
|
|
8773
8840
|
Chip_default as Chip,
|
|
8774
8841
|
ColorThemeSwitch_default as ColorThemeSwitch,
|
|
8842
|
+
DeveloperPage_default as DeveloperPage,
|
|
8775
8843
|
Div_default as Div,
|
|
8776
8844
|
Divider_default as Divider,
|
|
8777
8845
|
Dropdown_default as Dropdown,
|
|
@@ -8836,7 +8904,7 @@ export {
|
|
|
8836
8904
|
useMediaQuery,
|
|
8837
8905
|
usePageResize,
|
|
8838
8906
|
usePageScroll,
|
|
8839
|
-
|
|
8907
|
+
useTheme31 as useTheme,
|
|
8840
8908
|
useUrlQuery
|
|
8841
8909
|
};
|
|
8842
8910
|
//# sourceMappingURL=index.mjs.map
|