eddev 0.2.0-beta.0 → 0.2.0-beta.12

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.
Files changed (92) hide show
  1. package/build/build-favicon.d.ts +1 -0
  2. package/build/build-favicon.js +71 -0
  3. package/build/create-serverless-dev-worker.d.ts +3 -0
  4. package/build/create-serverless-dev-worker.js +99 -0
  5. package/build/get-webpack-config.js +19 -11
  6. package/build/reporter.js +0 -109
  7. package/build/serverless/create-next-app.d.ts +3 -0
  8. package/build/serverless/create-next-app.js +213 -70
  9. package/build/state/serverless-state.d.ts +26 -0
  10. package/build/state/serverless-state.js +2 -0
  11. package/build/workers/serverless-worker-dev-script.d.ts +1 -0
  12. package/build/workers/serverless-worker-dev-script.js +21 -0
  13. package/{cli/prepare-next.d.ts → build/workers/serverless-worker-script.d.ts} +0 -0
  14. package/{cli/prepare-next.js → build/workers/serverless-worker-script.js} +0 -0
  15. package/cli/build.dev.js +30 -7
  16. package/cli/build.prod.js +5 -0
  17. package/cli/cli.js +24 -5
  18. package/cli/display/components/DevCLIDisplay.d.ts +3 -0
  19. package/cli/display/components/DevCLIDisplay.js +20 -1
  20. package/cli/display/components/ServerlessDisplay.d.ts +9 -0
  21. package/cli/display/components/ServerlessDisplay.js +68 -0
  22. package/components/NextRouter.d.ts +9 -0
  23. package/components/NextRouter.js +36 -0
  24. package/config/config-schema.d.ts +50 -0
  25. package/config/config-schema.js +18 -0
  26. package/config/create-schema-file.d.ts +1 -0
  27. package/config/create-schema-file.js +20 -0
  28. package/config/get-config.d.ts +36 -0
  29. package/config/get-config.js +32 -0
  30. package/config/index.d.ts +2 -0
  31. package/config/index.js +14 -0
  32. package/config/parse-config.d.ts +23 -0
  33. package/config/parse-config.js +8 -0
  34. package/config/print-zod-errors.d.ts +2 -0
  35. package/config/print-zod-errors.js +14 -0
  36. package/dev-ui/components/BreakpointItemHeader.d.ts +11 -0
  37. package/dev-ui/components/BreakpointItemHeader.js +50 -0
  38. package/dev-ui/components/BreakpointList.d.ts +6 -0
  39. package/dev-ui/components/BreakpointList.js +38 -0
  40. package/dev-ui/components/DevUI.d.ts +2 -0
  41. package/dev-ui/components/DevUI.js +19 -0
  42. package/dev-ui/components/Launcher.d.ts +9 -0
  43. package/dev-ui/components/Launcher.js +118 -0
  44. package/dev-ui/components/PanelWrapper.d.ts +4 -0
  45. package/dev-ui/components/PanelWrapper.js +21 -0
  46. package/dev-ui/components/Pill.d.ts +0 -0
  47. package/dev-ui/components/Pill.js +1 -0
  48. package/dev-ui/components/SpacingEditor.d.ts +2 -0
  49. package/dev-ui/components/SpacingEditor.js +10 -0
  50. package/dev-ui/components/Text.d.ts +39 -0
  51. package/dev-ui/components/Text.js +13 -0
  52. package/dev-ui/components/panels/SpacingEditor.d.ts +2 -0
  53. package/dev-ui/components/panels/SpacingEditor.js +56 -0
  54. package/dev-ui/hooks/usePersistState.d.ts +1 -0
  55. package/dev-ui/hooks/usePersistState.js +28 -0
  56. package/dev-ui/icons.d.ts +11 -0
  57. package/dev-ui/icons.js +25 -0
  58. package/dev-ui/index.d.ts +1 -0
  59. package/dev-ui/index.js +5 -0
  60. package/dev-ui/panels.d.ts +11 -0
  61. package/dev-ui/panels.js +31 -0
  62. package/dev-ui/theme.d.ts +135 -0
  63. package/dev-ui/theme.js +45 -0
  64. package/entry/Root.js +6 -5
  65. package/hooks/useAppData.js +0 -1
  66. package/package.json +8 -7
  67. package/serverless/create-rpc-client.d.ts +32 -0
  68. package/serverless/create-rpc-client.js +20 -0
  69. package/serverless/define-api.d.ts +2 -0
  70. package/serverless/define-api.js +66 -0
  71. package/serverless/define-rpc-router.d.ts +2 -0
  72. package/serverless/define-rpc-router.js +27 -0
  73. package/serverless/error-codes.d.ts +2 -0
  74. package/serverless/error-codes.js +14 -0
  75. package/serverless/index.d.ts +4 -0
  76. package/serverless/index.js +16 -0
  77. package/serverless/rpc-provider.d.ts +1 -0
  78. package/serverless/rpc-provider.js +5 -0
  79. package/serverless-template/_utils/ed-config.ts +5 -0
  80. package/serverless-template/_utils/fetch-wordpress-props.ts +39 -0
  81. package/serverless-template/next.config.js +63 -42
  82. package/serverless-template/pages/[...slug].tsx +6 -7
  83. package/serverless-template/pages/_app.tsx +9 -5
  84. package/serverless-template/pages/_document.tsx +19 -0
  85. package/serverless-template/pages/index.tsx +3 -2
  86. package/style/createStitches.d.ts +63 -1
  87. package/style/createStitches.js +182 -40
  88. package/utils/getRepoName.d.ts +2 -2
  89. package/utils/getRepoName.js +14 -52
  90. package/build/prepare-next.d.ts +0 -1
  91. package/build/prepare-next.js +0 -5
  92. package/serverless-template/package-lock.json +0 -641
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.SpacingEditor = void 0;
4
+ var jsx_runtime_1 = require("react/jsx-runtime");
5
+ var _theme_1 = require("@theme");
6
+ function SpacingEditor() {
7
+ console.log("CONFIG", _theme_1.config);
8
+ return (0, jsx_runtime_1.jsx)("div", { children: "Spacing" }, void 0);
9
+ }
10
+ exports.SpacingEditor = SpacingEditor;
@@ -0,0 +1,39 @@
1
+ export declare const Text: import("@stitches/react/types/styled-component").StyledComponent<"div", {
2
+ variant?: "h1" | undefined;
3
+ }, {}, import("@stitches/react/types/css-util").CSS<{}, {
4
+ space: {
5
+ buttonHeight: string;
6
+ 0: string;
7
+ 1: string;
8
+ 2: string;
9
+ 3: string;
10
+ 4: string;
11
+ 5: string;
12
+ 6: string;
13
+ };
14
+ colors: {
15
+ bg: string;
16
+ bgHover: string;
17
+ bgHoverLight: string;
18
+ fg: string;
19
+ fgFaded: string;
20
+ };
21
+ fontSizes: {
22
+ sm: string;
23
+ md: string;
24
+ lg: string;
25
+ xl: string;
26
+ };
27
+ fonts: {
28
+ body: string;
29
+ mono: string;
30
+ };
31
+ radii: {
32
+ sm: string;
33
+ md: string;
34
+ lg: string;
35
+ };
36
+ transitions: {
37
+ default: string;
38
+ };
39
+ }, import("@stitches/react/types/config").DefaultThemeMap, {}>>;
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Text = void 0;
4
+ var theme_1 = require("../theme");
5
+ exports.Text = (0, theme_1.styled)("div", {
6
+ variants: {
7
+ variant: {
8
+ h1: {
9
+ fontSize: "$xl",
10
+ }
11
+ },
12
+ },
13
+ });
@@ -0,0 +1,2 @@
1
+ /// <reference types="react" />
2
+ export declare function SpacingEditor(): JSX.Element;
@@ -0,0 +1,56 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ exports.SpacingEditor = void 0;
15
+ var jsx_runtime_1 = require("react/jsx-runtime");
16
+ // @ts-ignore
17
+ var _theme_1 = require("@theme");
18
+ var react_1 = require("react");
19
+ var style_1 = require("../../../style");
20
+ var theme_1 = require("../../theme");
21
+ var BreakpointItemHeader_1 = require("../BreakpointItemHeader");
22
+ var BreakpointList_1 = require("../BreakpointList");
23
+ function SpacingEditor() {
24
+ // const [values, setValues] = usePersistState<ResponsiveSpace | undefined>("spacing", undefined)
25
+ var _a = (0, react_1.useState)(function () {
26
+ return __assign({}, _theme_1.originalConfig.responsive.space);
27
+ }), values = _a[0], setValues = _a[1];
28
+ console.log("CONFIG", _theme_1.originalConfig);
29
+ var parsedBreakpoints = (0, style_1.parseBreakpoints)(_theme_1.originalConfig.breakpoints, _theme_1.originalConfig.media);
30
+ console.log("A");
31
+ var info = (0, style_1.parseResponsiveObject)(parsedBreakpoints, values ? values[0] : {});
32
+ return ((0, jsx_runtime_1.jsx)("div", { children: (0, jsx_runtime_1.jsxs)(SpacingTable, { children: [(0, jsx_runtime_1.jsxs)(TableHeaderRow, { children: [(0, jsx_runtime_1.jsx)(TableCell, { children: "Token" }, void 0), (0, jsx_runtime_1.jsx)(TableCell, { children: (0, jsx_runtime_1.jsx)(BreakpointList_1.BreakpointList, { renderBreakpoint: function (bp, i) {
33
+ var bpInfo = info.find(function (item) { return item.breakpoint === bp; });
34
+ return (0, jsx_runtime_1.jsx)(BreakpointItemHeader_1.BreakpointColumnHeader, { name: bp, defined: !!(bpInfo === null || bpInfo === void 0 ? void 0 : bpInfo.defined) }, void 0);
35
+ } }, void 0) }, void 0)] }, void 0), Object.entries(values || {}).map(function (_a) {
36
+ var token = _a[0], value = _a[1];
37
+ console.log("B", token, value);
38
+ var info = (0, style_1.parseResponsiveObject)(parsedBreakpoints, value);
39
+ return ((0, jsx_runtime_1.jsxs)(TableRow, { children: [(0, jsx_runtime_1.jsx)(TableCell, { children: token }, void 0), (0, jsx_runtime_1.jsx)(TableCell, { children: (0, jsx_runtime_1.jsx)(BreakpointList_1.BreakpointList, { renderBreakpoint: function (bp, i) {
40
+ console.log("VALUE", value);
41
+ var bpInfo = info.find(function (item) { return item.breakpoint === bp; });
42
+ return value["@" + bp];
43
+ } }, void 0) }, void 0)] }, token));
44
+ })] }, void 0) }, void 0));
45
+ }
46
+ exports.SpacingEditor = SpacingEditor;
47
+ var SpacingTable = (0, theme_1.styled)("div", {
48
+ display: "table",
49
+ });
50
+ var TableRow = (0, theme_1.styled)("div", {
51
+ display: "table-row",
52
+ });
53
+ var TableHeaderRow = (0, theme_1.styled)(TableRow, {});
54
+ var TableCell = (0, theme_1.styled)("div", {
55
+ display: "table-cell",
56
+ });
@@ -0,0 +1 @@
1
+ export declare function usePersistState<T>(id: string, initial: T): [T, (value: T) => void];
@@ -0,0 +1,28 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.usePersistState = void 0;
4
+ var react_1 = require("react");
5
+ var get = function (id, fallback) {
6
+ if (fallback === void 0) { fallback = undefined; }
7
+ var value = localStorage.getItem("devui_" + id);
8
+ if (value !== null) {
9
+ return JSON.parse(value);
10
+ }
11
+ else {
12
+ return fallback;
13
+ }
14
+ };
15
+ var set = function (id, value) {
16
+ localStorage.setItem("devui_" + id, JSON.stringify(value));
17
+ };
18
+ function usePersistState(id, initial) {
19
+ var _a = (0, react_1.useState)(function () { return get(id, initial); }), value = _a[0], setValue = _a[1];
20
+ return [
21
+ value,
22
+ function (value) {
23
+ set(id, value);
24
+ setValue(value);
25
+ },
26
+ ];
27
+ }
28
+ exports.usePersistState = usePersistState;
@@ -0,0 +1,11 @@
1
+ /// <reference types="react" />
2
+ export declare const bolt: JSX.Element;
3
+ export declare const typography: JSX.Element;
4
+ export declare const ruler: JSX.Element;
5
+ export declare const structure: JSX.Element;
6
+ export declare const code: JSX.Element;
7
+ export declare const share: JSX.Element;
8
+ export declare const close: JSX.Element;
9
+ export declare const check: JSX.Element;
10
+ export declare const checkEmpty: JSX.Element;
11
+ export declare const checkFilled: JSX.Element;
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ exports.checkFilled = exports.checkEmpty = exports.check = exports.close = exports.share = exports.code = exports.structure = exports.ruler = exports.typography = exports.bolt = void 0;
15
+ var jsx_runtime_1 = require("react/jsx-runtime");
16
+ exports.bolt = ((0, jsx_runtime_1.jsxs)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: [(0, jsx_runtime_1.jsx)("g", { children: (0, jsx_runtime_1.jsx)("rect", { fill: "none", height: "24", width: "24" }, void 0) }, void 0), (0, jsx_runtime_1.jsx)("g", { children: (0, jsx_runtime_1.jsx)("path", { d: "M11,21h-1l1-7H6.74c0,0,3.68-6.46,6.26-11h1l-1,7h4.28L11,21z" }, void 0) }, void 0)] }), void 0));
17
+ exports.typography = ((0, jsx_runtime_1.jsx)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: (0, jsx_runtime_1.jsx)("path", { d: "M2.5 4v3h5v12h3V7h5V4h-13zm19 5h-9v3h3v7h3v-7h3V9z" }, void 0) }), void 0));
18
+ exports.ruler = ((0, jsx_runtime_1.jsxs)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: [(0, jsx_runtime_1.jsx)("path", { d: "M0 0h24v24H0V0z", fill: "none" }, void 0), (0, jsx_runtime_1.jsx)("path", { d: "M23 6H1v12h22V6zm-2 10H3V8h2v4h2V8h2v4h2V8h2v4h2V8h2v4h2V8h2v8z" }, void 0)] }), void 0));
19
+ exports.structure = ((0, jsx_runtime_1.jsxs)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", enableBackground: "new 0 0 24 24", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: [(0, jsx_runtime_1.jsx)("g", { children: (0, jsx_runtime_1.jsx)("rect", { fill: "none", height: "24", width: "24" }, void 0) }, void 0), (0, jsx_runtime_1.jsx)("polygon", { points: "22,11 22,3 15,3 15,6 9,6 9,3 2,3 2,11 9,11 9,8 11,8 11,18 15,18 15,21 22,21 22,13 15,13 15,16 13,16 13,8 15,8 15,11" }, void 0)] }), void 0));
20
+ exports.code = ((0, jsx_runtime_1.jsxs)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: [(0, jsx_runtime_1.jsx)("path", { d: "M0 0h24v24H0V0z", fill: "none" }, void 0), (0, jsx_runtime_1.jsx)("path", { d: "M9.4 16.6L4.8 12l4.6-4.6L8 6l-6 6 6 6 1.4-1.4zm5.2 0l4.6-4.6-4.6-4.6L16 6l6 6-6 6-1.4-1.4z" }, void 0)] }), void 0));
21
+ exports.share = ((0, jsx_runtime_1.jsxs)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", enableBackground: "new 0 0 24 24", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: [(0, jsx_runtime_1.jsx)("g", { children: (0, jsx_runtime_1.jsx)("rect", { fill: "none", height: "24", width: "24" }, void 0) }, void 0), (0, jsx_runtime_1.jsx)("g", { children: (0, jsx_runtime_1.jsxs)("g", { children: [(0, jsx_runtime_1.jsx)("g", { children: (0, jsx_runtime_1.jsx)("polygon", { points: "23,3 1,3 1,13 3,13 3,5 21,5 21,21 23,21" }, void 0) }, void 0), (0, jsx_runtime_1.jsx)("g", { children: (0, jsx_runtime_1.jsx)("circle", { cx: "9", cy: "10", r: "4" }, void 0) }, void 0), (0, jsx_runtime_1.jsx)("g", { children: (0, jsx_runtime_1.jsx)("path", { d: "M15.39,16.56C13.71,15.7,11.53,15,9,15c-2.53,0-4.71,0.7-6.39,1.56C1.61,17.07,1,18.1,1,19.22V22h16v-2.78 C17,18.1,16.39,17.07,15.39,16.56z" }, void 0) }, void 0)] }, void 0) }, void 0)] }), void 0));
22
+ exports.close = ((0, jsx_runtime_1.jsxs)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: [(0, jsx_runtime_1.jsx)("path", { d: "M0 0h24v24H0V0z", fill: "none" }, void 0), (0, jsx_runtime_1.jsx)("path", { d: "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12 19 6.41z" }, void 0)] }), void 0));
23
+ exports.check = ((0, jsx_runtime_1.jsxs)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: [(0, jsx_runtime_1.jsx)("path", { d: "M0 0h24v24H0V0z", fill: "none" }, void 0), (0, jsx_runtime_1.jsx)("path", { d: "M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41L9 16.17z" }, void 0)] }), void 0));
24
+ exports.checkEmpty = ((0, jsx_runtime_1.jsxs)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: [(0, jsx_runtime_1.jsx)("path", { d: "M0 0h24v24H0V0z", fill: "none" }, void 0), (0, jsx_runtime_1.jsx)("path", { d: "M19 5v14H5V5h14m2-2H3v18h18V3z" }, void 0)] }), void 0));
25
+ exports.checkFilled = ((0, jsx_runtime_1.jsxs)("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", height: "24px", viewBox: "0 0 24 24", width: "24px", fill: "#000000" }, { children: [(0, jsx_runtime_1.jsx)("path", { d: "M0 0h24v24H0V0z", fill: "none" }, void 0), (0, jsx_runtime_1.jsx)("path", { d: "M21 3H3v18h18V3zM10 17l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z" }, void 0)] }), void 0));
@@ -0,0 +1 @@
1
+ export { DevUI } from "./components/DevUI";
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DevUI = void 0;
4
+ var DevUI_1 = require("./components/DevUI");
5
+ Object.defineProperty(exports, "DevUI", { enumerable: true, get: function () { return DevUI_1.DevUI; } });
@@ -0,0 +1,11 @@
1
+ import { ComponentType, ReactNode } from "react";
2
+ declare type DevUIPanelItem = {
3
+ label: string;
4
+ icon: ReactNode;
5
+ component: ComponentType;
6
+ };
7
+ export declare const DEV_UI_PANELS: {
8
+ [key: string]: DevUIPanelItem;
9
+ };
10
+ export declare type PanelID = keyof typeof DEV_UI_PANELS;
11
+ export {};
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DEV_UI_PANELS = void 0;
4
+ var jsx_runtime_1 = require("react/jsx-runtime");
5
+ var SpacingEditor_1 = require("./components/panels/SpacingEditor");
6
+ var icons_1 = require("./icons");
7
+ var TempComponent = function () {
8
+ return (0, jsx_runtime_1.jsx)("div", { children: "Test" }, void 0);
9
+ };
10
+ exports.DEV_UI_PANELS = {
11
+ typography: {
12
+ label: "Typography",
13
+ icon: icons_1.typography,
14
+ component: TempComponent,
15
+ },
16
+ spacing: {
17
+ label: "Spacing",
18
+ icon: icons_1.ruler,
19
+ component: SpacingEditor_1.SpacingEditor,
20
+ },
21
+ page: {
22
+ label: "Page Data",
23
+ icon: icons_1.code,
24
+ component: TempComponent,
25
+ },
26
+ structure: {
27
+ label: "Page Structure",
28
+ icon: icons_1.structure,
29
+ component: TempComponent,
30
+ },
31
+ };
@@ -0,0 +1,135 @@
1
+ export declare const styled: <Type extends import("react").ComponentType<any> | keyof JSX.IntrinsicElements | import("@stitches/react/types/util").Function, Composers extends (string | import("react").ComponentType<any> | import("@stitches/react/types/util").Function | {
2
+ [name: string]: unknown;
3
+ })[], CSS = import("@stitches/react/types/css-util").CSS<{}, {
4
+ space: {
5
+ buttonHeight: string;
6
+ 0: string;
7
+ 1: string;
8
+ 2: string;
9
+ 3: string;
10
+ 4: string;
11
+ 5: string;
12
+ 6: string;
13
+ };
14
+ colors: {
15
+ bg: string;
16
+ bgHover: string;
17
+ bgHoverLight: string;
18
+ fg: string;
19
+ fgFaded: string;
20
+ };
21
+ fontSizes: {
22
+ sm: string;
23
+ md: string;
24
+ lg: string;
25
+ xl: string;
26
+ };
27
+ fonts: {
28
+ body: string;
29
+ mono: string;
30
+ };
31
+ radii: {
32
+ sm: string;
33
+ md: string;
34
+ lg: string;
35
+ };
36
+ transitions: {
37
+ default: string;
38
+ };
39
+ }, import("@stitches/react/types/config").DefaultThemeMap, {}>>(type: Type, ...composers: { [K in keyof Composers]: Composers[K] extends string | import("react").ComponentType<any> | import("@stitches/react/types/util").Function ? Composers[K] : import("@stitches/react/types/stitches").RemoveIndex<CSS> & {
40
+ variants?: {
41
+ [x: string]: {
42
+ [x: string]: CSS;
43
+ [x: number]: CSS;
44
+ };
45
+ } | undefined;
46
+ compoundVariants?: (("variants" extends keyof Composers[K] ? { [Name in keyof Composers[K][keyof Composers[K] & "variants"]]?: import("@stitches/react/types/util").String | import("@stitches/react/types/util").Widen<keyof Composers[K][keyof Composers[K] & "variants"][Name]> | undefined; } : import("@stitches/react/types/util").WideObject) & {
47
+ css: CSS;
48
+ })[] | undefined;
49
+ defaultVariants?: ("variants" extends keyof Composers[K] ? { [Name_1 in keyof Composers[K][keyof Composers[K] & "variants"]]?: import("@stitches/react/types/util").String | import("@stitches/react/types/util").Widen<keyof Composers[K][keyof Composers[K] & "variants"][Name_1]> | undefined; } : import("@stitches/react/types/util").WideObject) | undefined;
50
+ } & CSS & { [K2 in keyof Composers[K]]: K2 extends "compoundVariants" | "defaultVariants" | "variants" ? unknown : K2 extends keyof CSS ? CSS[K2] : unknown; }; }) => import("@stitches/react/types/styled-component").StyledComponent<Type, import("@stitches/react/types/styled-component").StyledComponentProps<Composers>, {}, import("@stitches/react/types/css-util").CSS<{}, {
51
+ space: {
52
+ buttonHeight: string;
53
+ 0: string;
54
+ 1: string;
55
+ 2: string;
56
+ 3: string;
57
+ 4: string;
58
+ 5: string;
59
+ 6: string;
60
+ };
61
+ colors: {
62
+ bg: string;
63
+ bgHover: string;
64
+ bgHoverLight: string;
65
+ fg: string;
66
+ fgFaded: string;
67
+ };
68
+ fontSizes: {
69
+ sm: string;
70
+ md: string;
71
+ lg: string;
72
+ xl: string;
73
+ };
74
+ fonts: {
75
+ body: string;
76
+ mono: string;
77
+ };
78
+ radii: {
79
+ sm: string;
80
+ md: string;
81
+ lg: string;
82
+ };
83
+ transitions: {
84
+ default: string;
85
+ };
86
+ }, import("@stitches/react/types/config").DefaultThemeMap, {}>>, css: <Composers extends (string | import("react").JSXElementConstructor<any> | import("react").ExoticComponent<any> | import("@stitches/react/types/util").Function | {
87
+ [name: string]: unknown;
88
+ })[], CSS = import("@stitches/react/types/css-util").CSS<{}, {
89
+ space: {
90
+ buttonHeight: string;
91
+ 0: string;
92
+ 1: string;
93
+ 2: string;
94
+ 3: string;
95
+ 4: string;
96
+ 5: string;
97
+ 6: string;
98
+ };
99
+ colors: {
100
+ bg: string;
101
+ bgHover: string;
102
+ bgHoverLight: string;
103
+ fg: string;
104
+ fgFaded: string;
105
+ };
106
+ fontSizes: {
107
+ sm: string;
108
+ md: string;
109
+ lg: string;
110
+ xl: string;
111
+ };
112
+ fonts: {
113
+ body: string;
114
+ mono: string;
115
+ };
116
+ radii: {
117
+ sm: string;
118
+ md: string;
119
+ lg: string;
120
+ };
121
+ transitions: {
122
+ default: string;
123
+ };
124
+ }, import("@stitches/react/types/config").DefaultThemeMap, {}>>(...composers: { [K in keyof Composers]: Composers[K] extends string | import("react").JSXElementConstructor<any> | import("react").ExoticComponent<any> | import("@stitches/react/types/util").Function ? Composers[K] : import("@stitches/react/types/stitches").RemoveIndex<CSS> & {
125
+ variants?: {
126
+ [x: string]: {
127
+ [x: string]: CSS;
128
+ [x: number]: CSS;
129
+ };
130
+ } | undefined;
131
+ compoundVariants?: (("variants" extends keyof Composers[K] ? { [Name in keyof Composers[K][keyof Composers[K] & "variants"]]?: import("@stitches/react/types/util").String | import("@stitches/react/types/util").Widen<keyof Composers[K][keyof Composers[K] & "variants"][Name]> | undefined; } : import("@stitches/react/types/util").WideObject) & {
132
+ css: CSS;
133
+ })[] | undefined;
134
+ defaultVariants?: ("variants" extends keyof Composers[K] ? { [Name_1 in keyof Composers[K][keyof Composers[K] & "variants"]]?: import("@stitches/react/types/util").String | import("@stitches/react/types/util").Widen<keyof Composers[K][keyof Composers[K] & "variants"][Name_1]> | undefined; } : import("@stitches/react/types/util").WideObject) | undefined;
135
+ } & CSS & { [K2 in keyof Composers[K]]: K2 extends "compoundVariants" | "defaultVariants" | "variants" ? unknown : K2 extends keyof CSS ? CSS[K2] : unknown; }; }) => import("@stitches/react/types/styled-component").CssComponent<import("@stitches/react/types/styled-component").StyledComponentType<Composers>, import("@stitches/react/types/styled-component").StyledComponentProps<Composers>, {}, CSS>;
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+ var _a;
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.css = exports.styled = void 0;
5
+ var react_1 = require("@stitches/react");
6
+ exports.styled = (_a = (0, react_1.createStitches)({
7
+ theme: {
8
+ space: {
9
+ buttonHeight: "26px",
10
+ 0: "4px",
11
+ 1: "8px",
12
+ 2: "12px",
13
+ 3: "16px",
14
+ 4: "24px",
15
+ 5: "32px",
16
+ 6: "48px",
17
+ },
18
+ colors: {
19
+ bg: "#222222",
20
+ bgHover: "#444444",
21
+ bgHoverLight: "#333333",
22
+ fg: "#ffffff",
23
+ fgFaded: "#aaaaaa",
24
+ },
25
+ fontSizes: {
26
+ sm: "12px",
27
+ md: "14px",
28
+ lg: "18px",
29
+ xl: "24px",
30
+ },
31
+ fonts: {
32
+ body: '"Roboto", Helvetica, sans-serif',
33
+ mono: '"Roboto Mono", Menlo, monospace',
34
+ },
35
+ radii: {
36
+ sm: "4px",
37
+ md: "8px",
38
+ lg: "16px",
39
+ },
40
+ transitions: {
41
+ default: "0.2s ease",
42
+ },
43
+ },
44
+ prefix: "eddev",
45
+ }), _a.styled), exports.css = _a.css;
package/entry/Root.js CHANGED
@@ -34,13 +34,14 @@ var jsx_runtime_1 = require("react/jsx-runtime");
34
34
  // @ts-ignore
35
35
  var views_1 = __importStar(require("@manifest/views"));
36
36
  var react_1 = require("react");
37
+ var dev_ui_1 = require("../dev-ui");
37
38
  var routing_1 = require("../routing");
38
39
  function Root() {
39
40
  var route = (0, routing_1.useRoute)();
40
- return ((0, jsx_runtime_1.jsx)(react_1.Fragment, { children: (0, jsx_runtime_1.jsx)(views_1.App, { children: (0, jsx_runtime_1.jsx)(routing_1.Switch, { children: Object.entries(views_1.default).map(function (_a) {
41
- var _b, _c;
42
- var name = _a[0], Component = _a[1];
43
- return ((0, jsx_runtime_1.jsx)(routing_1.Route, __assign({ match: function (route) { var _a; return ((_a = route.data) === null || _a === void 0 ? void 0 : _a.view) === name; } }, { children: (0, jsx_runtime_1.jsx)(Component, __assign({}, (_c = (_b = route.data) === null || _b === void 0 ? void 0 : _b.viewData) === null || _c === void 0 ? void 0 : _c.data), void 0) }), name));
44
- }) }, void 0) }, void 0) }, void 0));
41
+ return ((0, jsx_runtime_1.jsxs)(react_1.Fragment, { children: [process.devUI ? (0, jsx_runtime_1.jsx)(dev_ui_1.DevUI, {}, void 0) : null, (0, jsx_runtime_1.jsx)(views_1.App, { children: (0, jsx_runtime_1.jsx)(routing_1.Switch, { children: Object.entries(views_1.default).map(function (_a) {
42
+ var _b, _c;
43
+ var name = _a[0], Component = _a[1];
44
+ return ((0, jsx_runtime_1.jsx)(routing_1.Route, __assign({ match: function (route) { var _a; return ((_a = route.data) === null || _a === void 0 ? void 0 : _a.view) === name; } }, { children: (0, jsx_runtime_1.jsx)(Component, __assign({}, (_c = (_b = route.data) === null || _b === void 0 ? void 0 : _b.viewData) === null || _c === void 0 ? void 0 : _c.data), void 0) }), name));
45
+ }) }, void 0) }, void 0)] }, void 0));
45
46
  }
46
47
  exports.default = Root;
@@ -18,7 +18,6 @@ function useAppData(selector) {
18
18
  // @ts-ignore
19
19
  if (process.serverless) {
20
20
  var value = (0, react_1.useContext)(serverlessAppContext_1.ServerlessAppDataContext);
21
- console.log("VALUE IS", value);
22
21
  if (selector)
23
22
  return selector(value);
24
23
  return value;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eddev",
3
- "version": "0.2.0-beta.0",
3
+ "version": "0.2.0-beta.12",
4
4
  "main": "./index.js",
5
5
  "license": "MIT",
6
6
  "bin": {
@@ -16,6 +16,7 @@
16
16
  "@types/babel__traverse": "^7.14.2",
17
17
  "@types/chokidar": "^2.1.3",
18
18
  "@types/fs-extra": "^9.0.13",
19
+ "@types/git-repo-name": "^1.0.1",
19
20
  "@types/inquirer": "^8.1.1",
20
21
  "@types/loadable__component": "^5.13.4",
21
22
  "@types/node": "^16.7.10",
@@ -26,6 +27,7 @@
26
27
  "@types/url-parse": "^1.4.4",
27
28
  "@types/webpack-dev-server": "^3.11.2",
28
29
  "csstype": "^3.0.9",
30
+ "next": "^12.0.10",
29
31
  "react-html-props": "^1.0.32"
30
32
  },
31
33
  "dependencies": {
@@ -35,7 +37,6 @@
35
37
  "@babel/preset-react": "^7.14.5",
36
38
  "@babel/preset-typescript": "^7.15.0",
37
39
  "@babel/traverse": "^7.15.4",
38
- "@boost/log": "^3.0.0",
39
40
  "@graphql-codegen/cli": "^2.2.0",
40
41
  "@graphql-codegen/core": "^2.1.0",
41
42
  "@graphql-codegen/typescript": "^2.2.1",
@@ -60,34 +61,34 @@
60
61
  "dotenv": "^10.0.0",
61
62
  "error-overlay-webpack-plugin": "^1.0.0",
62
63
  "error-stack-parser": "^2.0.6",
63
- "execa": "^6.0.0",
64
64
  "friendly-errors-webpack-plugin": "^1.7.0",
65
65
  "fs-extra": "^10.0.0",
66
- "git-remote-origin-url": "^3.1.0",
66
+ "git-repo-name": "^1.0.1",
67
67
  "glob": "^7.1.7",
68
68
  "glob-promise": "^4.2.0",
69
69
  "graphql": "^15.5.3",
70
- "history": "^5.0.1",
71
70
  "ink": "^3.2.0",
72
71
  "inquirer": "^8.1.2",
73
72
  "mini-css-extract-plugin": "^2.2.2",
74
73
  "next-transpile-modules": "^9.0.0",
75
74
  "postcss-loader": "^6.1.1",
76
75
  "qs": "^6.10.1",
77
- "react-dev-utils": "^12.0.0-next.37",
78
76
  "react-error-overlay": "^6.0.9",
79
77
  "react-inspector": "^5.1.1",
80
78
  "react-merge-refs": "^1.1.0",
81
79
  "react-refresh": "^0.10.0",
82
80
  "rimraf": "^3.0.2",
83
81
  "swr": "^1.0.1",
84
- "typescript": "^4.4.2",
82
+ "to-icon": "^1.1.4",
83
+ "typescript": "^4.5.5",
85
84
  "url-parse": "^1.5.3",
86
85
  "webpack": "^5.52.0",
87
86
  "webpack-bundle-analyzer": "^4.5.0",
88
87
  "webpack-dev-server": "^3.11.2",
89
88
  "webpack-hot-middleware": "^2.25.0",
90
89
  "webpack-virtual-modules": "^0.4.3",
90
+ "zod": "^3.11.6",
91
+ "zod-to-json-schema": "^3.11.3",
91
92
  "zustand": "^3.5.10"
92
93
  },
93
94
  "peerDependencies": {
@@ -0,0 +1,32 @@
1
+ export declare function createRPCClient(): {
2
+ Provider: ({ client, queryClient, children, isPrepass, ssrContext, }: {
3
+ queryClient: QueryClient;
4
+ client: import("@trpc/react").TRPCClient<import("@trpc/server").AnyRouter<any>>;
5
+ children: import("react").ReactNode;
6
+ isPrepass?: boolean | undefined;
7
+ ssrContext?: unknown;
8
+ }) => JSX.Element;
9
+ createClient: (opts: import("@trpc/react").CreateTRPCClientOptions<import("@trpc/server").AnyRouter<any>>) => import("@trpc/react").TRPCClient<import("@trpc/server").AnyRouter<any>>;
10
+ useContext: () => import("@trpc/react/dist/declarations/src/internals/context").TRPCContextState<import("@trpc/server").AnyRouter<any>, unknown>;
11
+ useQuery: <TPath extends string>(pathAndInput: [TPath, (null | undefined)?], opts?: import("@trpc/react").UseTRPCQueryOptions<TPath, unknown, any, import("@trpc/react").TRPCClientErrorLike<import("@trpc/server").AnyRouter<any>>> | undefined) => UseQueryResult<{ [TPath_1 in keyof TRouter["_def"]["queries"]]: {
12
+ input: import("@trpc/server").inferProcedureInput<TRouter["_def"]["queries"][TPath_1]>;
13
+ output: import("@trpc/server").ThenArg<ReturnType<TRouter["_def"]["queries"][TPath_1]["call"]>>;
14
+ }; }[TPath_2]["output"], import("@trpc/react").TRPCClientErrorLike<TRouter>>;
15
+ useMutation: <TPath_1 extends string>(path: TPath_1 | [TPath_1], opts?: import("@trpc/react").UseTRPCMutationOptions<unknown, import("@trpc/react").TRPCClientErrorLike<import("@trpc/server").AnyRouter<any>>, any> | undefined) => UseMutationResult<{ [TPath_3 in keyof TRouter["_def"]["mutations"]]: {
16
+ input: import("@trpc/server").inferProcedureInput<TRouter["_def"]["mutations"][TPath_3]>;
17
+ output: import("@trpc/server").ThenArg<ReturnType<TRouter["_def"]["mutations"][TPath_3]["call"]>>;
18
+ }; }[TPath_1_1]["output"], import("@trpc/react").TRPCClientErrorLike<TRouter>, { [TPath_3 in keyof TRouter["_def"]["mutations"]]: {
19
+ input: import("@trpc/server").inferProcedureInput<TRouter["_def"]["mutations"][TPath_3]>;
20
+ output: import("@trpc/server").ThenArg<ReturnType<TRouter["_def"]["mutations"][TPath_3]["call"]>>;
21
+ }; }[TPath_1_1]["input"], unknown>;
22
+ useSubscription: <TPath_2 extends string, TOutput extends any>(pathAndInput: [TPath_2, (null | undefined)?], opts: {
23
+ enabled?: boolean | undefined;
24
+ onError?: ((err: import("@trpc/react").TRPCClientErrorLike<import("@trpc/server").AnyRouter<any>>) => void) | undefined;
25
+ onNext: (data: TOutput) => void;
26
+ }) => void;
27
+ useDehydratedState: (client: import("@trpc/react").TRPCClient<import("@trpc/server").AnyRouter<any>>, trpcState: any) => any;
28
+ useInfiniteQuery: <TPath_3 extends never>(pathAndInput: [path: TPath_3, input: Omit<unknown, "cursor">], opts?: import("@trpc/react").UseTRPCInfiniteQueryOptions<TPath_3, Omit<unknown, "cursor">, any, import("@trpc/react").TRPCClientErrorLike<import("@trpc/server").AnyRouter<any>>> | undefined) => UseInfiniteQueryResult<{ [TPath_1 in keyof TRouter["_def"]["queries"]]: {
29
+ input: import("@trpc/server").inferProcedureInput<TRouter["_def"]["queries"][TPath_1]>;
30
+ output: import("@trpc/server").ThenArg<ReturnType<TRouter["_def"]["queries"][TPath_1]["call"]>>;
31
+ }; }[TPath_3_1]["output"], import("@trpc/react").TRPCClientErrorLike<TRouter>>;
32
+ };
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ exports.createRPCClient = void 0;
15
+ var react_1 = require("@trpc/react");
16
+ function createRPCClient() {
17
+ var trpc = (0, react_1.createReactQueryHooks)();
18
+ return __assign({}, trpc);
19
+ }
20
+ exports.createRPCClient = createRPCClient;
@@ -0,0 +1,2 @@
1
+ import { NextApiHandler } from "next/types";
2
+ export declare function defineAPI(handler: NextApiHandler): NextApiHandler<any>;