@xwadex/fesd-next 0.2.9 → 0.3.1
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/components/Demo.js +23 -0
- package/dist/components/index.js +1 -0
- package/dist/hooks/index.js +1 -0
- package/dist/hooks/usePrevState.js +10 -0
- package/dist/index.js +3 -0
- package/dist/styles/components/Demo.scss +3 -0
- package/dist/styles/components/index.scss +1 -0
- package/dist/styles/main.scss +1 -0
- package/dist/styles/uis/Demo.scss +3 -0
- package/dist/styles/uis/index.scss +1 -0
- package/dist/types/components/Demo.d.ts +6 -0
- package/dist/types/components/index.d.ts +1 -0
- package/dist/types/hooks/index.d.ts +1 -0
- package/dist/types/hooks/usePrevState.d.ts +3 -0
- package/dist/types/index.d.ts +3 -0
- package/package.json +34 -15
- package/clients/MyClientComponent.d.ts +0 -3
- package/clients/MyClientComponent.js +0 -13
- package/clients/MyClientComponent2.d.ts +0 -3
- package/clients/MyClientComponent2.js +0 -12
- package/clients/index.d.ts +0 -2
- package/clients/index.js +0 -2
- package/index.d.ts +0 -2
- package/index.js +0 -2
- package/servers/MyComponent.d.ts +0 -1
- package/servers/MyComponent.js +0 -4
- package/servers/index.d.ts +0 -1
- package/servers/index.js +0 -1
- package/styles/clients/MyClientComponent.module.scss +0 -3
- package/styles/clients/MyClientComponent.scss +0 -3
- package/types/index.d.ts +0 -6
- package/types/index.js +0 -1
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
|
|
4
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
5
|
+
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
6
|
+
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
7
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
8
|
+
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
9
|
+
import React, { useEffect, useState } from 'react';
|
|
10
|
+
import { usePathname } from 'next/navigation';
|
|
11
|
+
export var Demo = function Demo(_ref) {
|
|
12
|
+
var title = _ref.title;
|
|
13
|
+
var pathname = usePathname();
|
|
14
|
+
var _useState = useState(title),
|
|
15
|
+
_useState2 = _slicedToArray(_useState, 1),
|
|
16
|
+
state = _useState2[0];
|
|
17
|
+
useEffect(function () {
|
|
18
|
+
console.log("pathname", pathname);
|
|
19
|
+
}, [pathname]);
|
|
20
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
21
|
+
className: "test"
|
|
22
|
+
}, "Demo:", state, ", ", pathname);
|
|
23
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Demo } from "./Demo";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { usePrevious } from "./usePrevState";
|
package/dist/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@forward "Demo";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@forward "components";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@forward "Demo";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Demo } from "./Demo";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { usePrevious } from "./usePrevState";
|
package/package.json
CHANGED
|
@@ -1,26 +1,45 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xwadex/fesd-next",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
"
|
|
3
|
+
"version": "0.3.1",
|
|
4
|
+
"private": false,
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"module": "dist/index.js",
|
|
7
|
+
"types": "dist/types/index.d.ts",
|
|
7
8
|
"files": [
|
|
8
|
-
"
|
|
9
|
+
"dist"
|
|
9
10
|
],
|
|
11
|
+
"scripts": {
|
|
12
|
+
"publish:patch": "pnpm version patch",
|
|
13
|
+
"publish:push": "git add . && git commit -m 'Patch Package Version' && git push",
|
|
14
|
+
"publish:npm": "pnpm publish:patch && pnpm publish:push && pnpm publish --access=public"
|
|
15
|
+
},
|
|
10
16
|
"exports": {
|
|
11
17
|
".": {
|
|
12
|
-
"
|
|
13
|
-
"
|
|
18
|
+
"import": "./dist/index.js",
|
|
19
|
+
"require": "./dist/index.js",
|
|
20
|
+
"types": "./dist/types/index.d.ts"
|
|
21
|
+
},
|
|
22
|
+
"./components": {
|
|
23
|
+
"import": "./dist/components/index.js",
|
|
24
|
+
"require": "./dist/components/index.js",
|
|
25
|
+
"types": "./dist/types/components/index.d.ts"
|
|
14
26
|
},
|
|
15
|
-
"./
|
|
16
|
-
|
|
27
|
+
"./hooks": {
|
|
28
|
+
"import": "./dist/hooks/index.js",
|
|
29
|
+
"require": "./dist/hooks/index.js",
|
|
30
|
+
"types": "./dist/types/hooks/index.d.ts"
|
|
31
|
+
},
|
|
32
|
+
"./styles/*": "./dist/styles/*"
|
|
17
33
|
},
|
|
18
34
|
"peerDependencies": {
|
|
19
|
-
"
|
|
20
|
-
"react
|
|
21
|
-
"
|
|
22
|
-
"
|
|
23
|
-
"
|
|
24
|
-
"
|
|
35
|
+
"next": ">=15",
|
|
36
|
+
"react": ">=18",
|
|
37
|
+
"react-dom": ">=18",
|
|
38
|
+
"framer-motion": ">=12.0.0",
|
|
39
|
+
"react-icons": ">=5.2.1",
|
|
40
|
+
"tua-body-scroll-lock": ">=1.5.1"
|
|
41
|
+
},
|
|
42
|
+
"devDependencies": {
|
|
43
|
+
"@types/body-scroll-lock": ">=3.1.2"
|
|
25
44
|
}
|
|
26
45
|
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
-
import { useEffect, useState } from "react";
|
|
4
|
-
import styles from "../styles/clients/MyClientComponent.module.scss";
|
|
5
|
-
const MyClientComponent = ({ name }) => {
|
|
6
|
-
const [state, setstate] = useState(0);
|
|
7
|
-
useEffect(() => {
|
|
8
|
-
console.log('hello!');
|
|
9
|
-
}, []);
|
|
10
|
-
return _jsxs("div", { className: styles.root, children: ["This is the component, name :", _jsxs("span", { children: [name !== null && name !== void 0 ? name : "empty", "13249849994984898"] }), _jsx("span", { children: state }), _jsx("button", { onClick: () => setstate(prev => prev + 1), children: "+" })] });
|
|
11
|
-
};
|
|
12
|
-
MyClientComponent.displayName = "MyClientComponent";
|
|
13
|
-
export default MyClientComponent;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
-
import { useEffect, useState } from "react";
|
|
4
|
-
const MyClientComponent2 = ({ name }) => {
|
|
5
|
-
const [state, setstate] = useState(0);
|
|
6
|
-
useEffect(() => {
|
|
7
|
-
console.log('hello!');
|
|
8
|
-
}, []);
|
|
9
|
-
return _jsxs("div", { children: ["This is the component, name :", _jsx("span", { children: name !== null && name !== void 0 ? name : "empty" }), _jsx("span", { children: state }), _jsx("button", { onClick: () => setstate(prev => prev + 1), children: "+" })] });
|
|
10
|
-
};
|
|
11
|
-
MyClientComponent2.displayName = "MyClientComponent2";
|
|
12
|
-
export default MyClientComponent2;
|
package/clients/index.d.ts
DELETED
package/clients/index.js
DELETED
package/index.d.ts
DELETED
package/index.js
DELETED
package/servers/MyComponent.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function MyComponent(): import("react/jsx-runtime").JSX.Element;
|
package/servers/MyComponent.js
DELETED
package/servers/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./MyComponent";
|
package/servers/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./MyComponent";
|
package/types/index.d.ts
DELETED
package/types/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|