@vicacha-devs/medusa-plugin-barcode 0.0.0-stage → 0.1.0
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/.medusa/server/src/admin/index.cjs +3960 -0
- package/.medusa/server/src/admin/index.js +3938 -0
- package/.medusa/server/src/api/admin/barcodes/[barcode]/route.js +43 -0
- package/.medusa/server/src/api/admin/barcodes/batch/route.js +9 -0
- package/.medusa/server/src/api/admin/barcodes/bulk-generate/route.js +9 -0
- package/.medusa/server/src/api/admin/barcodes/cache/route.js +25 -0
- package/.medusa/server/src/api/admin/barcodes/count-sessions/[id]/apply/route.js +13 -0
- package/.medusa/server/src/api/admin/barcodes/count-sessions/[id]/scan/route.js +13 -0
- package/.medusa/server/src/api/admin/barcodes/count-sessions/route.js +27 -0
- package/.medusa/server/src/api/admin/barcodes/create-from-barcode/route.js +9 -0
- package/.medusa/server/src/api/admin/barcodes/lookup/route.js +12 -0
- package/.medusa/server/src/api/admin/barcodes/print/route.js +11 -0
- package/.medusa/server/src/api/admin/barcodes/route.js +27 -0
- package/.medusa/server/src/api/admin/barcodes/scan/route.js +23 -0
- package/.medusa/server/src/api/admin/barcodes/tags/[id]/route.js +28 -0
- package/.medusa/server/src/api/admin/barcodes/tags/route.js +25 -0
- package/.medusa/server/src/api/admin/barcodes/templates/route.js +40 -0
- package/.medusa/server/src/api/admin/plugin/route.js +4 -0
- package/.medusa/server/src/api/admin/variants/barcode/[code]/route.js +28 -0
- package/.medusa/server/src/api/middlewares.js +73 -0
- package/.medusa/server/src/api/store/barcodes/[code]/route.js +28 -0
- package/.medusa/server/src/api/store/barcodes/[code]/verify/route.js +20 -0
- package/.medusa/server/src/api/store/plugin/route.js +4 -0
- package/.medusa/server/src/api/store/variants/barcode/[code]/route.js +28 -0
- package/.medusa/server/src/api/validators.js +173 -0
- package/.medusa/server/src/hooks/index.js +202 -0
- package/.medusa/server/src/index.js +5 -0
- package/.medusa/server/src/jobs/purge-expired-barcode-cache.js +10 -0
- package/.medusa/server/src/modules/barcode/index.js +16 -0
- package/.medusa/server/src/modules/barcode/migrations/Migration20260522000000.js +165 -0
- package/.medusa/server/src/modules/barcode/models/index.js +162 -0
- package/.medusa/server/src/modules/barcode/operations/context.js +2 -0
- package/.medusa/server/src/modules/barcode/operations/data-service.js +10 -0
- package/.medusa/server/src/modules/barcode/operations/generation.js +33 -0
- package/.medusa/server/src/modules/barcode/operations/index.js +9 -0
- package/.medusa/server/src/modules/barcode/operations/labels.js +57 -0
- package/.medusa/server/src/modules/barcode/operations/lookup.js +135 -0
- package/.medusa/server/src/modules/barcode/operations/maintenance.js +37 -0
- package/.medusa/server/src/modules/barcode/operations/stock-count.js +129 -0
- package/.medusa/server/src/modules/barcode/operations/tags.js +298 -0
- package/.medusa/server/src/modules/barcode/providers/index.js +721 -0
- package/.medusa/server/src/modules/barcode/service.js +161 -0
- package/.medusa/server/src/modules/barcode/types.js +21 -0
- package/.medusa/server/src/modules/barcode/utils/barcode-parser.js +399 -0
- package/.medusa/server/src/modules/barcode/utils/label-printer.js +533 -0
- package/.medusa/server/src/modules/barcode/utils/normalize-product.js +443 -0
- package/.medusa/server/src/modules/barcode/utils/security.js +114 -0
- package/.medusa/server/src/modules/barcode/utils/svg-renderer.js +492 -0
- package/.medusa/server/src/rbac.js +130 -0
- package/.medusa/server/src/sdk/index.js +164 -0
- package/.medusa/server/src/subscribers/product-created.js +34 -0
- package/.medusa/server/src/types/index.js +2 -0
- package/.medusa/server/src/ui/index.js +138 -0
- package/.medusa/server/src/workflows/apply-inventory-count.js +68 -0
- package/.medusa/server/src/workflows/batch-barcode-import.js +153 -0
- package/.medusa/server/src/workflows/bulk-generate-variant-barcodes.js +143 -0
- package/.medusa/server/src/workflows/generate-barcode-tag.js +44 -0
- package/.medusa/server/src/workflows/helpers.js +15 -0
- package/.medusa/server/src/workflows/index.js +7 -0
- package/.medusa/server/src/workflows/lookup-and-create-product.js +215 -0
- package/.medusa/server/src/workflows/scan-inventory-count.js +15 -0
- package/LICENSE +21 -0
- package/README.md +844 -2
- package/package.json +134 -3
- package/src/__tests__/barcode.spec.ts +836 -0
- package/src/__tests__/medusa-shim.mjs +331 -0
- package/src/__tests__/register-ts-resolver.mjs +135 -0
- package/src/admin/README.md +134 -0
- package/src/admin/components/barcode-studio-header.tsx +73 -0
- package/src/admin/components/batch-import-section.tsx +99 -0
- package/src/admin/components/dynamic-qr-tag-drawer-form.tsx +230 -0
- package/src/admin/components/dynamic-qr-tag-form.tsx +129 -0
- package/src/admin/components/dynamic-qr-tags-table.tsx +136 -0
- package/src/admin/components/gtin-lookup-section.tsx +155 -0
- package/src/admin/components/index.tsx +14 -0
- package/src/admin/components/label-designer-section.tsx +151 -0
- package/src/admin/components/label-output-section.tsx +63 -0
- package/src/admin/components/overview-cards.tsx +98 -0
- package/src/admin/components/product-barcode-card.tsx +127 -0
- package/src/admin/components/providers-cache-table.tsx +61 -0
- package/src/admin/components/providers-overview-section.tsx +49 -0
- package/src/admin/components/rbac-guard.tsx +153 -0
- package/src/admin/components/stock-take-scanner-section.tsx +116 -0
- package/src/admin/components/stock-take-sessions-section.tsx +109 -0
- package/src/admin/hooks/use-barcode-studio.ts +466 -0
- package/src/admin/hooks/use-product-barcodes.ts +139 -0
- package/src/admin/i18n/README.md +130 -0
- package/src/admin/i18n/index.ts +36 -0
- package/src/admin/i18n/json/ar.json +157 -0
- package/src/admin/i18n/json/de.json +157 -0
- package/src/admin/i18n/json/en.json +157 -0
- package/src/admin/i18n/json/es.json +157 -0
- package/src/admin/i18n/json/fr.json +157 -0
- package/src/admin/i18n/json/it.json +157 -0
- package/src/admin/i18n/json/nl.json +157 -0
- package/src/admin/i18n/json/pl.json +157 -0
- package/src/admin/i18n/json/pt.json +157 -0
- package/src/admin/i18n/json/tr.json +157 -0
- package/src/admin/routes/barcodes/lookup/page.tsx +75 -0
- package/src/admin/routes/barcodes/page.tsx +212 -0
- package/src/admin/routes/barcodes/print/page.tsx +67 -0
- package/src/admin/routes/barcodes/providers/page.tsx +66 -0
- package/src/admin/routes/barcodes/stock-take/page.tsx +74 -0
- package/src/admin/routes/barcodes/tags/@create/page.tsx +56 -0
- package/src/admin/routes/barcodes/tags/page.tsx +72 -0
- package/src/admin/tsconfig.json +20 -0
- package/src/admin/vite-env.d.ts +1 -0
- package/src/admin/widgets/product-barcode-widget.tsx +43 -0
- package/src/api/README.md +117 -0
- package/src/api/admin/barcodes/[barcode]/route.ts +64 -0
- package/src/api/admin/barcodes/batch/route.ts +12 -0
- package/src/api/admin/barcodes/bulk-generate/route.ts +12 -0
- package/src/api/admin/barcodes/cache/route.ts +35 -0
- package/src/api/admin/barcodes/count-sessions/[id]/apply/route.ts +17 -0
- package/src/api/admin/barcodes/count-sessions/[id]/scan/route.ts +17 -0
- package/src/api/admin/barcodes/count-sessions/route.ts +43 -0
- package/src/api/admin/barcodes/create-from-barcode/route.ts +16 -0
- package/src/api/admin/barcodes/lookup/route.ts +19 -0
- package/src/api/admin/barcodes/print/route.ts +18 -0
- package/src/api/admin/barcodes/route.ts +36 -0
- package/src/api/admin/barcodes/scan/route.ts +32 -0
- package/src/api/admin/barcodes/tags/[id]/route.ts +41 -0
- package/src/api/admin/barcodes/tags/route.ts +36 -0
- package/src/api/admin/barcodes/templates/route.ts +51 -0
- package/src/api/admin/plugin/route.ts +5 -0
- package/src/api/admin/variants/barcode/[code]/route.ts +36 -0
- package/src/api/middlewares.ts +91 -0
- package/src/api/store/barcodes/[code]/route.ts +43 -0
- package/src/api/store/barcodes/[code]/verify/route.ts +35 -0
- package/src/api/store/plugin/route.ts +5 -0
- package/src/api/store/variants/barcode/[code]/route.ts +36 -0
- package/src/api/validators.ts +217 -0
- package/src/hooks/index.ts +270 -0
- package/src/index.ts +4 -0
- package/src/jobs/README.md +54 -0
- package/src/jobs/purge-expired-barcode-cache.ts +18 -0
- package/src/links/README.md +44 -0
- package/src/modules/README.md +85 -0
- package/src/modules/barcode/index.ts +18 -0
- package/src/modules/barcode/migrations/Migration20260522000000.ts +225 -0
- package/src/modules/barcode/models/index.ts +168 -0
- package/src/modules/barcode/operations/context.ts +14 -0
- package/src/modules/barcode/operations/data-service.ts +10 -0
- package/src/modules/barcode/operations/generation.ts +57 -0
- package/src/modules/barcode/operations/index.ts +8 -0
- package/src/modules/barcode/operations/labels.ts +90 -0
- package/src/modules/barcode/operations/lookup.ts +202 -0
- package/src/modules/barcode/operations/maintenance.ts +53 -0
- package/src/modules/barcode/operations/stock-count.ts +217 -0
- package/src/modules/barcode/operations/tags.ts +425 -0
- package/src/modules/barcode/providers/index.ts +958 -0
- package/src/modules/barcode/service.ts +243 -0
- package/src/modules/barcode/types.ts +297 -0
- package/src/modules/barcode/utils/barcode-parser.ts +453 -0
- package/src/modules/barcode/utils/label-printer.ts +641 -0
- package/src/modules/barcode/utils/normalize-product.ts +524 -0
- package/src/modules/barcode/utils/security.ts +136 -0
- package/src/modules/barcode/utils/svg-renderer.ts +574 -0
- package/src/providers/README.md +105 -0
- package/src/rbac.ts +144 -0
- package/src/sdk/index.ts +253 -0
- package/src/subscribers/README.md +73 -0
- package/src/subscribers/product-created.ts +45 -0
- package/src/types/index.ts +1 -0
- package/src/types/medusa-ui.d.ts +118 -0
- package/src/ui/index.tsx +311 -0
- package/src/workflows/README.md +56 -0
- package/src/workflows/apply-inventory-count.ts +115 -0
- package/src/workflows/batch-barcode-import.ts +218 -0
- package/src/workflows/bulk-generate-variant-barcodes.ts +214 -0
- package/src/workflows/generate-barcode-tag.ts +85 -0
- package/src/workflows/helpers.ts +21 -0
- package/src/workflows/index.ts +6 -0
- package/src/workflows/lookup-and-create-product.ts +298 -0
- package/src/workflows/scan-inventory-count.ts +45 -0
- package/tsconfig.json +40 -0
package/package.json
CHANGED
|
@@ -1,6 +1,137 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vicacha-devs/medusa-plugin-barcode",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Unified 4-in-1 Barcode, GS1, Dynamic QR, Multi-Provider GTIN Lookup, Thermal/Sheet Label Printing (HTML/SVG & ZPL II), Anti-Counterfeit Verification & Warehouse Stock-Take Scanner plugin for Medusa v2.",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"barcode",
|
|
7
|
+
"ean13",
|
|
8
|
+
"gs1",
|
|
9
|
+
"gs1-128",
|
|
10
|
+
"inventory-count",
|
|
11
|
+
"label-printing",
|
|
12
|
+
"medusa",
|
|
13
|
+
"medusa-plugin",
|
|
14
|
+
"medusa-plugin-barcode",
|
|
15
|
+
"medusa-plugin-integration",
|
|
16
|
+
"medusa-v2",
|
|
17
|
+
"open-food-facts",
|
|
18
|
+
"pos",
|
|
19
|
+
"qr-code",
|
|
20
|
+
"upc",
|
|
21
|
+
"zpl"
|
|
22
|
+
],
|
|
23
|
+
"license": "MIT",
|
|
24
|
+
"author": "Vicacha Devs",
|
|
25
|
+
"repository": {
|
|
26
|
+
"type": "git",
|
|
27
|
+
"url": "git+https://github.com/Vicacha-Devs/medusa-plugins.git",
|
|
28
|
+
"directory": "packages/barcode"
|
|
29
|
+
},
|
|
30
|
+
"files": [
|
|
31
|
+
".medusa/server",
|
|
32
|
+
"src",
|
|
33
|
+
"README.md",
|
|
34
|
+
"LICENSE",
|
|
35
|
+
"tsconfig.json"
|
|
36
|
+
],
|
|
37
|
+
"type": "module",
|
|
38
|
+
"exports": {
|
|
39
|
+
"./package.json": "./package.json",
|
|
40
|
+
".": {
|
|
41
|
+
"import": "./.medusa/server/src/index.js",
|
|
42
|
+
"default": "./.medusa/server/src/index.js"
|
|
43
|
+
},
|
|
44
|
+
"./admin": {
|
|
45
|
+
"import": "./.medusa/server/src/admin/index.js",
|
|
46
|
+
"default": "./.medusa/server/src/admin/index.js"
|
|
47
|
+
},
|
|
48
|
+
"./ui": {
|
|
49
|
+
"import": "./src/ui/index.tsx",
|
|
50
|
+
"default": "./.medusa/server/src/ui/index.js"
|
|
51
|
+
},
|
|
52
|
+
"./hooks": {
|
|
53
|
+
"import": "./src/hooks/index.ts",
|
|
54
|
+
"default": "./.medusa/server/src/hooks/index.js"
|
|
55
|
+
},
|
|
56
|
+
"./sdk": {
|
|
57
|
+
"import": "./src/sdk/index.ts",
|
|
58
|
+
"default": "./.medusa/server/src/sdk/index.js"
|
|
59
|
+
},
|
|
60
|
+
"./types": {
|
|
61
|
+
"import": "./src/types/index.ts",
|
|
62
|
+
"default": "./.medusa/server/src/types/index.js"
|
|
63
|
+
},
|
|
64
|
+
"./workflows": "./.medusa/server/src/workflows/index.js",
|
|
65
|
+
"./.medusa/server/src/modules/*": "./.medusa/server/src/modules/*/index.js",
|
|
66
|
+
"./modules/*": "./.medusa/server/src/modules/*/index.js",
|
|
67
|
+
"./providers/*": "./.medusa/server/src/providers/*/index.js",
|
|
68
|
+
"./rbac": {
|
|
69
|
+
"import": "./src/rbac.ts",
|
|
70
|
+
"default": "./.medusa/server/src/rbac.js"
|
|
71
|
+
},
|
|
72
|
+
"./*": "./.medusa/server/src/*.js"
|
|
73
|
+
},
|
|
74
|
+
"devDependencies": {
|
|
75
|
+
"@hookform/resolvers": "5.7.1",
|
|
76
|
+
"@medusajs/admin-sdk": "2.23.0",
|
|
77
|
+
"@medusajs/admin-shared": "2.23.0",
|
|
78
|
+
"@medusajs/cli": "2.23.0",
|
|
79
|
+
"@medusajs/core-flows": "2.23.0",
|
|
80
|
+
"@medusajs/dashboard": "2.23.0",
|
|
81
|
+
"@medusajs/framework": "2.23.0",
|
|
82
|
+
"@medusajs/icons": "2.23.0",
|
|
83
|
+
"@medusajs/js-sdk": "2.23.0",
|
|
84
|
+
"@medusajs/medusa": "2.23.0",
|
|
85
|
+
"@medusajs/test-utils": "2.23.0",
|
|
86
|
+
"@medusajs/types": "2.23.0",
|
|
87
|
+
"@medusajs/ui": "4.3.0",
|
|
88
|
+
"@mikro-orm/migrations": "6.4.3",
|
|
89
|
+
"@swc/core": "1.7.28",
|
|
90
|
+
"@types/node": "20.0.0",
|
|
91
|
+
"@types/react": "^19.3.0",
|
|
92
|
+
"@types/react-dom": "^19.3.0",
|
|
93
|
+
"jiti": "2.0.0",
|
|
94
|
+
"prop-types": "15.8.1",
|
|
95
|
+
"react": "^19.3.1",
|
|
96
|
+
"react-dom": "^19.3.1",
|
|
97
|
+
"react-hook-form": "7.92.0",
|
|
98
|
+
"react-i18next": "18.0.1",
|
|
99
|
+
"react-router-dom": "7.18.5",
|
|
100
|
+
"ts-node": "10.9.2",
|
|
101
|
+
"tsc-alias": "^1.9.2",
|
|
102
|
+
"typescript": "5.6.2",
|
|
103
|
+
"vite": "^8.3.8"
|
|
104
|
+
},
|
|
105
|
+
"peerDependencies": {
|
|
106
|
+
"@hookform/resolvers": "5.7.1",
|
|
107
|
+
"@medusajs/admin-sdk": "2.23.0",
|
|
108
|
+
"@medusajs/admin-shared": "2.23.0",
|
|
109
|
+
"@medusajs/cli": "2.23.0",
|
|
110
|
+
"@medusajs/core-flows": "2.23.0",
|
|
111
|
+
"@medusajs/framework": "2.23.0",
|
|
112
|
+
"@medusajs/icons": "2.23.0",
|
|
113
|
+
"@medusajs/js-sdk": "2.23.0",
|
|
114
|
+
"@medusajs/medusa": "2.23.0",
|
|
115
|
+
"@medusajs/test-utils": "2.23.0",
|
|
116
|
+
"@medusajs/types": "2.23.0",
|
|
117
|
+
"@medusajs/ui": "4.3.0",
|
|
118
|
+
"react": "^19.3.1",
|
|
119
|
+
"react-dom": "^19.3.1",
|
|
120
|
+
"react-hook-form": "7.92.0",
|
|
121
|
+
"react-i18next": "18.0.1",
|
|
122
|
+
"react-router-dom": "7.18.5",
|
|
123
|
+
"zod": "4.6.7"
|
|
124
|
+
},
|
|
125
|
+
"engines": {
|
|
126
|
+
"node": ">=22.22.0"
|
|
127
|
+
},
|
|
128
|
+
"scripts": {
|
|
129
|
+
"build": "medusa plugin:build && tsc-alias -p tsconfig.json --resolve-full-paths",
|
|
130
|
+
"publish:local": "medusa plugin:publish",
|
|
131
|
+
"dev": "medusa plugin:develop",
|
|
132
|
+
"lint": "medusa lint",
|
|
133
|
+
"typecheck": "tsc --noEmit",
|
|
134
|
+
"test": "node --import ./src/__tests__/register-ts-resolver.mjs --import ../plugin-testing/register-js-extension.mjs --test src/__tests__/*.spec.ts",
|
|
135
|
+
"clean": "rm -rf .medusa node_modules"
|
|
136
|
+
}
|
|
6
137
|
}
|