@bbodek/hooks 0.0.18 → 0.0.20
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/README.md +1 -1
- package/dist/FilterCalendarPanel-tgOkj1yi-Ca95srv1.js +46 -0
- package/dist/FilterCalendarPanel-tgOkj1yi-Ca95srv1.js.map +1 -0
- package/dist/FilterMultiSelectPanel-BKJ7F-nP-DqwwAW3z.js +51 -0
- package/dist/FilterMultiSelectPanel-BKJ7F-nP-DqwwAW3z.js.map +1 -0
- package/dist/FilterSelectOptionPanel-uodA0iXc-kXTbi7Ni.js +22 -0
- package/dist/FilterSelectOptionPanel-uodA0iXc-kXTbi7Ni.js.map +1 -0
- package/dist/effects/useIsomorphicLayoutEffect/useIsomorphicLayoutEffect.d.ts +2 -2
- package/dist/effects/useIsomorphicLayoutEffect/useIsomorphicLayoutEffect.d.ts.map +1 -1
- package/dist/hooks/useComposeEventHandler/useComposeEventHandler.d.ts +1 -1
- package/dist/hooks/useComposeEventHandler/useComposeEventHandler.d.ts.map +1 -1
- package/dist/hooks/useDropzone/types/index.d.ts +2 -2
- package/dist/hooks/useDropzone/types/index.d.ts.map +1 -1
- package/dist/hooks/useDropzone/useDropzoneInput.d.ts +3 -2
- package/dist/hooks/useDropzone/useDropzoneInput.d.ts.map +1 -1
- package/dist/hooks/useDropzone/useDropzoneRoot.d.ts +15 -15
- package/dist/hooks/useDropzone/useDropzoneUpload.d.ts +1 -1
- package/dist/hooks/useDropzone/useDropzoneUpload.d.ts.map +1 -1
- package/dist/hooks/useExecuteFunction/useExecuteFunction.d.ts.map +1 -1
- package/dist/hooks/useForm/types/index.d.ts +1 -1
- package/dist/hooks/useForm/types/index.d.ts.map +1 -1
- package/dist/hooks/useForm/useForm.d.ts +2 -2
- package/dist/hooks/useForm/useForm.d.ts.map +1 -1
- package/dist/hooks/useResponsible/useResponsible.d.ts.map +1 -1
- package/dist/index-BotlieCc.js +37207 -0
- package/dist/index-BotlieCc.js.map +1 -0
- package/dist/index.es.js +6 -1
- package/dist/index.es.js.map +1 -1
- package/dist/useFilterSelectOptionPanel-E9OE1xmu-hQsWrD13.js +38 -0
- package/dist/useFilterSelectOptionPanel-E9OE1xmu-hQsWrD13.js.map +1 -0
- package/package.json +20 -18
- package/dist/hooks/useResponsible/effects/useSetResponsibleStatusEffect.d.ts +0 -1
- package/dist/hooks/useResponsible/effects/useSetResponsibleStatusEffect.d.ts.map +0 -1
package/dist/index.es.js
CHANGED
|
@@ -1,2 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
export { G as BREAKPOINT_SIZE, D as DROPZONE_ACTION_MAPPER, x as DROPZONE_REJECT_CODE_MAPPER, y as DROPZONE_REJECT_MESSAGE, R as RESPONSIBLE_STATUS, t as useClickOutSideEffect, s as useClickOutside, v as useComposeEventHandler, w as useDropzone, z as useExecuteFunction, p as useFirstRenderEffect, A as useForm, q as useIsomorphicLayoutEffect, E as useResponsible, r as useScrollLockEffect } from './index-BotlieCc.js';
|
|
2
|
+
import 'react';
|
|
3
|
+
import 'react/jsx-runtime';
|
|
4
|
+
import 'react-dom';
|
|
5
|
+
import 'fs';
|
|
6
|
+
import 'stream';
|
|
2
7
|
//# sourceMappingURL=index.es.js.map
|
package/dist/index.es.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.es.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"index.es.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { l as useFilterContext, u as useFilterPanelContext, m as FILTER_STEPS, B as Button, n as BUTTON_SIZES, o as BUTTON_THEMES } from './index-BotlieCc.js';
|
|
3
|
+
import { useCallback } from 'react';
|
|
4
|
+
|
|
5
|
+
const FilterSelectButton = ({ onClick, disabled }) => {
|
|
6
|
+
return (jsx("div", { className: 'border-t-in-gray-02 border-t p-4', children: jsx(Button, { label: '\uC120\uD0DD \uC644\uB8CC', theme: BUTTON_THEMES.PRIMARY, size: BUTTON_SIZES.SM, onClick: onClick, className: 'w-full', disabled: disabled }) }));
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
const useFilterSelectOptionPanel = () => {
|
|
10
|
+
const { toggleValues = null, selectValues, selectOptions, onChange, } = useFilterContext();
|
|
11
|
+
const { currentOptions, currentSelectValue, setCurrentSelectValue, setFilterStep, } = useFilterPanelContext();
|
|
12
|
+
const { key } = currentOptions;
|
|
13
|
+
const selectValue = selectValues?.[key] ?? null;
|
|
14
|
+
const _currentSelectValue = currentSelectValue?.[key] ?? null;
|
|
15
|
+
const value = selectValue ?? _currentSelectValue;
|
|
16
|
+
const options = selectOptions.find((option) => option.key === key);
|
|
17
|
+
const handleChange = useCallback(({ value }) => {
|
|
18
|
+
onChange({
|
|
19
|
+
toggleValues,
|
|
20
|
+
selectValues: {
|
|
21
|
+
...selectValues,
|
|
22
|
+
[key]: value,
|
|
23
|
+
},
|
|
24
|
+
});
|
|
25
|
+
setFilterStep(FILTER_STEPS.IDLE);
|
|
26
|
+
setCurrentSelectValue(null);
|
|
27
|
+
}, [key, currentSelectValue, selectValues]);
|
|
28
|
+
return {
|
|
29
|
+
models: {
|
|
30
|
+
value,
|
|
31
|
+
options,
|
|
32
|
+
},
|
|
33
|
+
operations: { handleChange, setCurrentSelectValue },
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
export { FilterSelectButton as F, useFilterSelectOptionPanel as u };
|
|
38
|
+
//# sourceMappingURL=useFilterSelectOptionPanel-E9OE1xmu-hQsWrD13.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useFilterSelectOptionPanel-E9OE1xmu-hQsWrD13.js","sources":["../../../node_modules/.pnpm/@bbodek+internal-ui@0.0.46_@bbodek+hooks@0.0.19_@bbodek+utils@0.0.16_react-dom@19.1.0_r_391de0e25676aa2bb3131b4638467e71/node_modules/@bbodek/internal-ui/dist/useFilterSelectOptionPanel-E9OE1xmu.js"],"sourcesContent":["import { jsx } from 'react/jsx-runtime';\nimport { B as Button, l as BUTTON_SIZES, m as BUTTON_THEMES, n as useFilterContext, u as useFilterPanelContext, o as FILTER_STEPS } from './index-Bt8RKgO9.js';\nimport { useCallback } from 'react';\n\nconst FilterSelectButton = ({ onClick, disabled }) => {\n return (jsx(\"div\", { className: 'border-t-in-gray-02 border-t p-4', children: jsx(Button, { label: '\\uC120\\uD0DD \\uC644\\uB8CC', theme: BUTTON_THEMES.PRIMARY, size: BUTTON_SIZES.SM, onClick: onClick, className: 'w-full', disabled: disabled }) }));\n};\n\nconst useFilterSelectOptionPanel = () => {\n const { toggleValues = null, selectValues, selectOptions, onChange, } = useFilterContext();\n const { currentOptions, currentSelectValue, setCurrentSelectValue, setFilterStep, } = useFilterPanelContext();\n const { key } = currentOptions;\n const selectValue = selectValues?.[key] ?? null;\n const _currentSelectValue = currentSelectValue?.[key] ?? null;\n const value = selectValue ?? _currentSelectValue;\n const options = selectOptions.find((option) => option.key === key);\n const handleChange = useCallback(({ value }) => {\n onChange({\n toggleValues,\n selectValues: {\n ...selectValues,\n [key]: value,\n },\n });\n setFilterStep(FILTER_STEPS.IDLE);\n setCurrentSelectValue(null);\n }, [key, currentSelectValue, selectValues]);\n return {\n models: {\n value,\n options,\n },\n operations: { handleChange, setCurrentSelectValue },\n };\n};\n\nexport { FilterSelectButton as F, useFilterSelectOptionPanel as u };\n//# sourceMappingURL=useFilterSelectOptionPanel-E9OE1xmu.js.map\n"],"names":[],"mappings":";;;;AAIK,MAAC,kBAAkB,GAAG,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,KAAK;AACtD,IAAI,QAAQ,GAAG,CAAC,KAAK,EAAE,EAAE,SAAS,EAAE,kCAAkC,EAAE,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,2BAA2B,EAAE,KAAK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nB,SAAS;AACT,QAAQ,UAAU,EAAE,EAAE,YAAY,EAAE,qBAAqB,EAAE;AAC3D,KAAK;AACL;;;;","x_google_ignoreList":[0]}
|
package/package.json
CHANGED
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bbodek/hooks",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.20",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "https://github.com/thebbodek/dotoli",
|
|
9
|
+
"directory": "apps/hooks"
|
|
10
|
+
},
|
|
6
11
|
"exports": {
|
|
7
12
|
".": {
|
|
8
13
|
"import": "./dist/index.es.js",
|
|
@@ -12,37 +17,34 @@
|
|
|
12
17
|
"files": [
|
|
13
18
|
"dist"
|
|
14
19
|
],
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"build": "rollup -c && tsc -p tsconfig.build.json && tsc-alias -p tsconfig.build.json",
|
|
18
|
-
"start": "next start",
|
|
19
|
-
"lint": "next lint"
|
|
20
|
+
"dependencies": {
|
|
21
|
+
"@bbodek/utils": "0.0.18"
|
|
20
22
|
},
|
|
21
|
-
"dependencies": {},
|
|
22
23
|
"peerDependencies": {
|
|
23
24
|
"next": "^15.3.1",
|
|
24
25
|
"react": "^19.1.0",
|
|
25
|
-
"react-dom": "^19.1.0"
|
|
26
|
-
"@bbodek/utils": "^0.0.6"
|
|
26
|
+
"react-dom": "^19.1.0"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
29
|
"next": "^15.3.1",
|
|
30
30
|
"react": "^19.1.0",
|
|
31
31
|
"react-dom": "^19.1.0",
|
|
32
|
-
"@bbodek/utils": "^0.0.6",
|
|
33
|
-
"@dotoli/eslint-config": "workspace:*",
|
|
34
|
-
"@dotoli/typescript-config": "workspace:*",
|
|
35
|
-
"@rollup/plugin-node-resolve": "^16.0.1",
|
|
36
|
-
"@rollup/plugin-terser": "^0.4.4",
|
|
37
32
|
"@types/node": "^20",
|
|
38
33
|
"@types/react": "^19",
|
|
39
34
|
"@types/react-dom": "^19",
|
|
40
35
|
"eslint": "^9.26.0",
|
|
41
36
|
"rollup": "^4.40.2",
|
|
42
|
-
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
43
|
-
"rollup-plugin-typescript2": "^0.36.0",
|
|
44
37
|
"tsc-alias": "^1.8.16",
|
|
45
38
|
"tslib": "^2.8.1",
|
|
46
|
-
"typescript": "^5.8.3"
|
|
39
|
+
"typescript": "^5.8.3",
|
|
40
|
+
"@dotoli/typescript-config": "0.0.0",
|
|
41
|
+
"@bbodek/eslint-config": "0.0.3",
|
|
42
|
+
"@dotoli/rollup-config": "0.0.0"
|
|
43
|
+
},
|
|
44
|
+
"scripts": {
|
|
45
|
+
"dev": "rollup -c --watch & tsc -p tsconfig.build.json --watch & tsc-alias -p tsconfig.build.json --watch",
|
|
46
|
+
"build": "rollup -c && tsc -p tsconfig.build.json && tsc-alias -p tsconfig.build.json",
|
|
47
|
+
"start": "next start",
|
|
48
|
+
"lint": "eslint \"./src\" --ext .ts,.tsx"
|
|
47
49
|
}
|
|
48
|
-
}
|
|
50
|
+
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=useSetResponsibleStatusEffect.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"useSetResponsibleStatusEffect.d.ts","sourceRoot":"","sources":["../../../../src/hooks/useResponsible/effects/useSetResponsibleStatusEffect.ts"],"names":[],"mappings":""}
|