2024-11-18
corvée(images) ajoute les images téléversées
1
.vscode/settings.json
vendored
|
|
@ -23,6 +23,7 @@
|
||||||
"Epingle",
|
"Epingle",
|
||||||
"EPINGLE",
|
"EPINGLE",
|
||||||
"EPINGLES",
|
"EPINGLES",
|
||||||
|
"etat",
|
||||||
"etats",
|
"etats",
|
||||||
"ETATS",
|
"ETATS",
|
||||||
"etendu",
|
"etendu",
|
||||||
|
|
|
||||||
43
pnpm-lock.yaml
generated
|
|
@ -1271,8 +1271,9 @@ packages:
|
||||||
resolution: {integrity: sha512-n8enUVCED/KVRQlab1hr3MVpcVMvxtZjmEa956u+4YijlmQED223XMSYj2tLuKvr4jcCTzNNMpQDUer72MMmzA==}
|
resolution: {integrity: sha512-n8enUVCED/KVRQlab1hr3MVpcVMvxtZjmEa956u+4YijlmQED223XMSYj2tLuKvr4jcCTzNNMpQDUer72MMmzA==}
|
||||||
engines: {node: '>= 14.16.0'}
|
engines: {node: '>= 14.16.0'}
|
||||||
|
|
||||||
cipher-base@1.0.4:
|
cipher-base@1.0.5:
|
||||||
resolution: {integrity: sha512-Kkht5ye6ZGmwv40uUDZztayT2ThLQGfnj/T71N/XzeZeo3nf8foyW7zGTsPYkEya3m5f3cAypH+qe7YOrM1U2Q==}
|
resolution: {integrity: sha512-xq7ICKB4TMHUx7Tz1L9O2SGKOhYMOTR32oir45Bq28/AQTpHogKgHcoYFSdRbMtddl+ozNXfXY9jWcgYKmde0w==}
|
||||||
|
engines: {node: '>= 0.10'}
|
||||||
|
|
||||||
clean-stack@2.2.0:
|
clean-stack@2.2.0:
|
||||||
resolution: {integrity: sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==}
|
resolution: {integrity: sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==}
|
||||||
|
|
@ -1346,8 +1347,8 @@ packages:
|
||||||
cross-spawn@5.1.0:
|
cross-spawn@5.1.0:
|
||||||
resolution: {integrity: sha512-pTgQJ5KC0d2hcY8eyL1IzlBPYjTkyH72XRZPnLyKus2mBfNjQs3klqbJU2VILqZryAZUt9JOb3h/mWMy23/f5A==}
|
resolution: {integrity: sha512-pTgQJ5KC0d2hcY8eyL1IzlBPYjTkyH72XRZPnLyKus2mBfNjQs3klqbJU2VILqZryAZUt9JOb3h/mWMy23/f5A==}
|
||||||
|
|
||||||
cross-spawn@7.0.5:
|
cross-spawn@7.0.6:
|
||||||
resolution: {integrity: sha512-ZVJrKKYunU38/76t0RMOulHOnUcbU9GbpWKAOZ0mhjr7CX6FVrH+4FrAapSOekrgFQ3f/8gwMEuIft0aKq6Hug==}
|
resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==}
|
||||||
engines: {node: '>= 8'}
|
engines: {node: '>= 8'}
|
||||||
|
|
||||||
crypto-browserify@3.12.1:
|
crypto-browserify@3.12.1:
|
||||||
|
|
@ -1633,8 +1634,8 @@ packages:
|
||||||
resolution: {integrity: sha512-JrqFmyUl2PnPi1OvLyTVHnQvwQ0S+e6lGSwu8OkAZlSaNIZciTY2H/cOOROxsBA1m/LZNHDsqAgDZt6akWcjsQ==}
|
resolution: {integrity: sha512-JrqFmyUl2PnPi1OvLyTVHnQvwQ0S+e6lGSwu8OkAZlSaNIZciTY2H/cOOROxsBA1m/LZNHDsqAgDZt6akWcjsQ==}
|
||||||
engines: {node: '>=18'}
|
engines: {node: '>=18'}
|
||||||
|
|
||||||
flatted@3.3.1:
|
flatted@3.3.2:
|
||||||
resolution: {integrity: sha512-X8cqMLLie7KsNUDSdzeN8FYK9rEt4Dt67OsG/DNGnYTSDBG4uFAJFBnUeiV+zCVAvwFy56IjM9sH51jVaEhNxw==}
|
resolution: {integrity: sha512-AiwGJM8YcNOaobumgtng+6NHuOqC3A7MixFeDafM3X9cIUM+xUXoS5Vfgf+OihAYe20fxqNM9yPBXJzRtZ/4eA==}
|
||||||
|
|
||||||
focusable-selectors@0.8.4:
|
focusable-selectors@0.8.4:
|
||||||
resolution: {integrity: sha512-0XxbkD0KhOnX10qmnfF9U8DkDD8N/e4M77wMYw2Itoi4vdcoRjSkqXLZFIzkrLIOxzmzCGy88fNG1EbeXMD/zw==}
|
resolution: {integrity: sha512-0XxbkD0KhOnX10qmnfF9U8DkDD8N/e4M77wMYw2Itoi4vdcoRjSkqXLZFIzkrLIOxzmzCGy88fNG1EbeXMD/zw==}
|
||||||
|
|
@ -2288,8 +2289,8 @@ packages:
|
||||||
purify-ts@2.1.0:
|
purify-ts@2.1.0:
|
||||||
resolution: {integrity: sha512-+KNUHV9FxB9BbjadFdvxa+LNJIaqZmSF7CQH5Rv6+f0rBzsxm9FEqrvkALQbWYJobAja2ZCbBDUY7O4fH2znMA==}
|
resolution: {integrity: sha512-+KNUHV9FxB9BbjadFdvxa+LNJIaqZmSF7CQH5Rv6+f0rBzsxm9FEqrvkALQbWYJobAja2ZCbBDUY7O4fH2znMA==}
|
||||||
|
|
||||||
qs@6.13.0:
|
qs@6.13.1:
|
||||||
resolution: {integrity: sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==}
|
resolution: {integrity: sha512-EJPeIn0CYrGu+hli1xilKAPXODtJ12T0sP63Ijx2/khC2JtuaN3JyNIpvmnkmaEtha9ocbG4A4cMcr+TvqvwQg==}
|
||||||
engines: {node: '>=0.6'}
|
engines: {node: '>=0.6'}
|
||||||
|
|
||||||
querystring-es3@0.2.1:
|
querystring-es3@0.2.1:
|
||||||
|
|
@ -3850,7 +3851,7 @@ snapshots:
|
||||||
browserify-aes@1.2.0:
|
browserify-aes@1.2.0:
|
||||||
dependencies:
|
dependencies:
|
||||||
buffer-xor: 1.0.3
|
buffer-xor: 1.0.3
|
||||||
cipher-base: 1.0.4
|
cipher-base: 1.0.5
|
||||||
create-hash: 1.2.0
|
create-hash: 1.2.0
|
||||||
evp_bytestokey: 1.0.3
|
evp_bytestokey: 1.0.3
|
||||||
inherits: 2.0.4
|
inherits: 2.0.4
|
||||||
|
|
@ -3864,7 +3865,7 @@ snapshots:
|
||||||
|
|
||||||
browserify-des@1.0.2:
|
browserify-des@1.0.2:
|
||||||
dependencies:
|
dependencies:
|
||||||
cipher-base: 1.0.4
|
cipher-base: 1.0.5
|
||||||
des.js: 1.1.0
|
des.js: 1.1.0
|
||||||
inherits: 2.0.4
|
inherits: 2.0.4
|
||||||
safe-buffer: 5.2.1
|
safe-buffer: 5.2.1
|
||||||
|
|
@ -3948,7 +3949,7 @@ snapshots:
|
||||||
readdirp: 4.0.2
|
readdirp: 4.0.2
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
cipher-base@1.0.4:
|
cipher-base@1.0.5:
|
||||||
dependencies:
|
dependencies:
|
||||||
inherits: 2.0.4
|
inherits: 2.0.4
|
||||||
safe-buffer: 5.2.1
|
safe-buffer: 5.2.1
|
||||||
|
|
@ -4004,7 +4005,7 @@ snapshots:
|
||||||
|
|
||||||
create-hash@1.2.0:
|
create-hash@1.2.0:
|
||||||
dependencies:
|
dependencies:
|
||||||
cipher-base: 1.0.4
|
cipher-base: 1.0.5
|
||||||
inherits: 2.0.4
|
inherits: 2.0.4
|
||||||
md5.js: 1.3.5
|
md5.js: 1.3.5
|
||||||
ripemd160: 2.0.2
|
ripemd160: 2.0.2
|
||||||
|
|
@ -4012,7 +4013,7 @@ snapshots:
|
||||||
|
|
||||||
create-hmac@1.1.7:
|
create-hmac@1.1.7:
|
||||||
dependencies:
|
dependencies:
|
||||||
cipher-base: 1.0.4
|
cipher-base: 1.0.5
|
||||||
create-hash: 1.2.0
|
create-hash: 1.2.0
|
||||||
inherits: 2.0.4
|
inherits: 2.0.4
|
||||||
ripemd160: 2.0.2
|
ripemd160: 2.0.2
|
||||||
|
|
@ -4027,7 +4028,7 @@ snapshots:
|
||||||
shebang-command: 1.2.0
|
shebang-command: 1.2.0
|
||||||
which: 1.3.1
|
which: 1.3.1
|
||||||
|
|
||||||
cross-spawn@7.0.5:
|
cross-spawn@7.0.6:
|
||||||
dependencies:
|
dependencies:
|
||||||
path-key: 3.1.1
|
path-key: 3.1.1
|
||||||
shebang-command: 2.0.0
|
shebang-command: 2.0.0
|
||||||
|
|
@ -4219,7 +4220,7 @@ snapshots:
|
||||||
'@types/json-schema': 7.0.15
|
'@types/json-schema': 7.0.15
|
||||||
ajv: 6.12.6
|
ajv: 6.12.6
|
||||||
chalk: 4.1.2
|
chalk: 4.1.2
|
||||||
cross-spawn: 7.0.5
|
cross-spawn: 7.0.6
|
||||||
debug: 4.3.7
|
debug: 4.3.7
|
||||||
escape-string-regexp: 4.0.0
|
escape-string-regexp: 4.0.0
|
||||||
eslint-scope: 8.2.0
|
eslint-scope: 8.2.0
|
||||||
|
|
@ -4283,7 +4284,7 @@ snapshots:
|
||||||
|
|
||||||
execa@5.1.1:
|
execa@5.1.1:
|
||||||
dependencies:
|
dependencies:
|
||||||
cross-spawn: 7.0.5
|
cross-spawn: 7.0.6
|
||||||
get-stream: 6.0.1
|
get-stream: 6.0.1
|
||||||
human-signals: 2.1.0
|
human-signals: 2.1.0
|
||||||
is-stream: 2.0.1
|
is-stream: 2.0.1
|
||||||
|
|
@ -4369,15 +4370,15 @@ snapshots:
|
||||||
|
|
||||||
flat-cache@4.0.1:
|
flat-cache@4.0.1:
|
||||||
dependencies:
|
dependencies:
|
||||||
flatted: 3.3.1
|
flatted: 3.3.2
|
||||||
keyv: 4.5.4
|
keyv: 4.5.4
|
||||||
|
|
||||||
flat-cache@5.0.0:
|
flat-cache@5.0.0:
|
||||||
dependencies:
|
dependencies:
|
||||||
flatted: 3.3.1
|
flatted: 3.3.2
|
||||||
keyv: 4.5.4
|
keyv: 4.5.4
|
||||||
|
|
||||||
flatted@3.3.1: {}
|
flatted@3.3.2: {}
|
||||||
|
|
||||||
focusable-selectors@0.8.4: {}
|
focusable-selectors@0.8.4: {}
|
||||||
|
|
||||||
|
|
@ -4986,7 +4987,7 @@ snapshots:
|
||||||
dependencies:
|
dependencies:
|
||||||
'@types/json-schema': 7.0.15
|
'@types/json-schema': 7.0.15
|
||||||
|
|
||||||
qs@6.13.0:
|
qs@6.13.1:
|
||||||
dependencies:
|
dependencies:
|
||||||
side-channel: 1.0.6
|
side-channel: 1.0.6
|
||||||
|
|
||||||
|
|
@ -5521,7 +5522,7 @@ snapshots:
|
||||||
url@0.11.4:
|
url@0.11.4:
|
||||||
dependencies:
|
dependencies:
|
||||||
punycode: 1.4.1
|
punycode: 1.4.1
|
||||||
qs: 6.13.0
|
qs: 6.13.1
|
||||||
|
|
||||||
util-deprecate@1.0.2: {}
|
util-deprecate@1.0.2: {}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -46,7 +46,6 @@
|
||||||
--couleur-fond: rgb(236 234 235 / 80%);
|
--couleur-fond: rgb(236 234 235 / 80%);
|
||||||
/* Polices */
|
/* Polices */
|
||||||
--police-lato: "Lato", sans-serif;
|
--police-lato: "Lato", sans-serif;
|
||||||
--police-myriad: "Myriad", sans-serif;
|
|
||||||
/* Hauteurs de ligne */
|
/* Hauteurs de ligne */
|
||||||
--hauteur-ligne-classique: 1.5;
|
--hauteur-ligne-classique: 1.5;
|
||||||
--hauteur-ligne-moitie: 1.2;
|
--hauteur-ligne-moitie: 1.2;
|
||||||
|
|
|
||||||
|
After Width: | Height: | Size: 100 KiB |
|
After Width: | Height: | Size: 1.1 MiB |
|
After Width: | Height: | Size: 87 KiB |
|
Before Width: | Height: | Size: 96 KiB After Width: | Height: | Size: 121 KiB |
|
Before Width: | Height: | Size: 79 KiB After Width: | Height: | Size: 94 KiB |
|
Before Width: | Height: | Size: 96 KiB After Width: | Height: | Size: 109 KiB |
|
Before Width: | Height: | Size: 90 KiB After Width: | Height: | Size: 100 KiB |
|
Before Width: | Height: | Size: 97 KiB After Width: | Height: | Size: 105 KiB |
|
Before Width: | Height: | Size: 96 KiB After Width: | Height: | Size: 124 KiB |
|
Before Width: | Height: | Size: 90 KiB After Width: | Height: | Size: 115 KiB |
|
Before Width: | Height: | Size: 83 KiB After Width: | Height: | Size: 105 KiB |
|
Before Width: | Height: | Size: 71 KiB After Width: | Height: | Size: 91 KiB |
|
Before Width: | Height: | Size: 69 KiB After Width: | Height: | Size: 88 KiB |
|
Before Width: | Height: | Size: 80 KiB After Width: | Height: | Size: 95 KiB |
|
Before Width: | Height: | Size: 86 KiB After Width: | Height: | Size: 102 KiB |
|
Before Width: | Height: | Size: 91 KiB After Width: | Height: | Size: 108 KiB |
|
|
@ -34,16 +34,16 @@
|
||||||
],
|
],
|
||||||
"integrity": "sha512-wORZ0WkOfNuzAUKhf7XA8LXG4geR64dUCIHwukqdLnUhkEFdeLpLtmDfuYMl5Aff09c7XjJxUQIVGwRb8uTbcA=="
|
"integrity": "sha512-wORZ0WkOfNuzAUKhf7XA8LXG4geR64dUCIHwukqdLnUhkEFdeLpLtmDfuYMl5Aff09c7XjJxUQIVGwRb8uTbcA=="
|
||||||
},
|
},
|
||||||
"_index.CXGAS3st.js": {
|
|
||||||
"file": "index.CXGAS3st.js",
|
|
||||||
"name": "index",
|
|
||||||
"integrity": "sha512-eDANGhRhGm64JXPMqSK3b9l2B9IgUl4mo9ssnLZo8wcn8nWgv+R8JklbZ5xKI8JXxuLCYthYHsAuPG0ylMgKgg=="
|
|
||||||
},
|
|
||||||
"_index.CeK6pfoJ.js": {
|
"_index.CeK6pfoJ.js": {
|
||||||
"file": "index.CeK6pfoJ.js",
|
"file": "index.CeK6pfoJ.js",
|
||||||
"name": "index",
|
"name": "index",
|
||||||
"integrity": "sha512-cxTw0sKKut2H95JwMgiKgEVLyZ0QswK/HydKTapcqcs3w6xHIHNUpYBLdRzEYdeRfHKUsA0kvPNBXBk/QeazjQ=="
|
"integrity": "sha512-cxTw0sKKut2H95JwMgiKgEVLyZ0QswK/HydKTapcqcs3w6xHIHNUpYBLdRzEYdeRfHKUsA0kvPNBXBk/QeazjQ=="
|
||||||
},
|
},
|
||||||
|
"_index.DeCaB8sW.js": {
|
||||||
|
"file": "index.DeCaB8sW.js",
|
||||||
|
"name": "index",
|
||||||
|
"integrity": "sha512-VESVuActn/4kpl+gzqYgRTFoQLbW4WDZeuMjQEyixdpUaEK7n+ALNomAYHW9H2rNclHjlKCd8AIRi3Pnof+bpw=="
|
||||||
|
},
|
||||||
"_pipe.XPB0wEfw.js": {
|
"_pipe.XPB0wEfw.js": {
|
||||||
"file": "pipe.XPB0wEfw.js",
|
"file": "pipe.XPB0wEfw.js",
|
||||||
"name": "pipe",
|
"name": "pipe",
|
||||||
|
|
@ -54,7 +54,7 @@
|
||||||
"name": "api",
|
"name": "api",
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/constantes/api.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/constantes/api.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"integrity": "sha512-IwhkTU893yoVKm6XHK5H3hAtfFt/SDe0ftjM4h2RttKPvlxIl71FP6sOYCNeLEuGsuCx0Hz6FsrdqsUEqOpqVg=="
|
"integrity": "sha512-oDVrrWjz3SSnlBy/OeAAxg+LjpBmHDxBzGsUS1fqirjK1CP2l29BqQqM4rfdvE38iMsvu0WlEYve3uCmyB7PIA=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/cart.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/cart.ts": {
|
||||||
"file": "cart2.js",
|
"file": "cart2.js",
|
||||||
|
|
@ -68,7 +68,7 @@
|
||||||
"name": "dom",
|
"name": "dom",
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/constantes/dom.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/constantes/dom.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"integrity": "sha512-vXHO4Jy2lfm9PCvsOvkMcjB4+vGiuyqyugcDomkqWd1W4z7ugvBl7C000uKJAw3vPLlng2TqbqlIMx9eqplQMA=="
|
"integrity": "sha512-sSwUifw859f7ljok6cQWFI9El3qerOTqmW3nVQbjXUjYhTYT6G+iIEAUwVjsAFJw+opvE93EHcIkfETrKNVhFg=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts": {
|
||||||
"file": "messages3.js",
|
"file": "messages3.js",
|
||||||
|
|
@ -78,11 +78,11 @@
|
||||||
"integrity": "sha512-M8me/iGRLfItVHaEf+BhA3xdEIxEwdyNuN+H87daJ1jl1oOENbROB7ub6RPP47NdFsQUChTRphEhQglT+qc6RA=="
|
"integrity": "sha512-M8me/iGRLfItVHaEf+BhA3xdEIxEwdyNuN+H87daJ1jl1oOENbROB7ub6RPP47NdFsQUChTRphEhQglT+qc6RA=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/orders.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/orders.ts": {
|
||||||
"file": "orders3.js",
|
"file": "orders2.js",
|
||||||
"name": "orders",
|
"name": "orders",
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/constantes/orders.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/constantes/orders.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"integrity": "sha512-dLV15du4JF6iPF2I93pExJpqAG13hXNCrRj8hF1dO47SFaa/7S74hT3puqnojjF5g1vStbjuGX+dLVklMIZuOw=="
|
"integrity": "sha512-wV9B3cW/1TnjBcesuc4a2M+28+67nsmX2++/Up1QUraP4Bdzbn9RiToohkone5Z+1mZNOjB/Hrd8x7Gc+jtVvg=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/products.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/products.ts": {
|
||||||
"file": "products2.js",
|
"file": "products2.js",
|
||||||
|
|
@ -101,7 +101,7 @@
|
||||||
"_exports.DT-46nyp.js",
|
"_exports.DT-46nyp.js",
|
||||||
"_pipe.XPB0wEfw.js"
|
"_pipe.XPB0wEfw.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-QQ4AgRankxszy2lL9PwpKn4u1qftdAEfH2fjKIsz2r1r1vbAVy9RxvnRolMzQoDMp9Z5u0LYBibtRl0phcP6Bg=="
|
"integrity": "sha512-VOFE4Hcn84/zkx9+7f96xARQfIjFTjxj77+vPW+axDmgJdzTqzeepoUlWWlMvMhnXPzlZg8hECzJ9LPbbaMkdQ=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/dom.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/dom.ts": {
|
||||||
"file": "dom2.js",
|
"file": "dom2.js",
|
||||||
|
|
@ -124,7 +124,7 @@
|
||||||
"imports": [
|
"imports": [
|
||||||
"_exports.DT-46nyp.js"
|
"_exports.DT-46nyp.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-VCvTqmBichQ2MC4UG1jCaBSZYI814NOS6zm+RJJ8dfvdR9foeXGuvnAEtZAU1U4tBk79bkIHUc6O/hkR8JpcmA=="
|
"integrity": "sha512-ycCJdagUL+AOJ9CK7idsyochoV+fGvM1apEuijceXsjZ9RfROHMbweTcpZYs8OvQ8h/GVd6gP3F7ajOeNDLm6A=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/gardes.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/gardes.ts": {
|
||||||
"file": "gardes.js",
|
"file": "gardes.js",
|
||||||
|
|
@ -143,7 +143,7 @@
|
||||||
"_MaybeAsync.Ba-OfjWy.js",
|
"_MaybeAsync.Ba-OfjWy.js",
|
||||||
"_Either.wHNxn7Os.js"
|
"_Either.wHNxn7Os.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-cPmRTewvt0FOjnKDlX4Bj+7BhUXeBTVJc1FMaFYBFbiaePTsftZ084cwHuR2eQRV4dSoK6H0JfRwjAolgfcGQA=="
|
"integrity": "sha512-5w6tDnjHcmdQkNGKIfoCvHl92oc+ofbg4S0QY3PS5Fe7Opiwx2chB9+KWBBYBFek2mG3hekzTyznvrr7JZKYXA=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/messages.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/messages.ts": {
|
||||||
"file": "messages.js",
|
"file": "messages.js",
|
||||||
|
|
@ -151,7 +151,7 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/messages.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/messages.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/erreurs.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/erreurs.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
||||||
|
|
@ -162,7 +162,7 @@
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts"
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-fmTMGQ1CAm5f/E+VaFBldk3mzb47nIyaNZjs7WSrAOefIVDPqtpRAHFcyHuTYFZeq7QX5ApeEgUtvWyYHP2PHQ=="
|
"integrity": "sha512-mVB7iJ9eYAlGmsedqDBABBDBz7QBbEbJOira6EczLdLFjMoXRqOmBSvq/T2yTVPZE7Vm4bOy1MEseSxJRBt9Dw=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/nombres.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/nombres.ts": {
|
||||||
"file": "nombres.js",
|
"file": "nombres.js",
|
||||||
|
|
@ -178,14 +178,14 @@
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CeK6pfoJ.js",
|
"_index.CeK6pfoJ.js",
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/api.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/api.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/erreurs.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/erreurs.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/erreurs.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/erreurs.ts",
|
||||||
"_pipe.XPB0wEfw.js",
|
"_pipe.XPB0wEfw.js",
|
||||||
"_exports.DT-46nyp.js"
|
"_exports.DT-46nyp.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-3DwXfy4COJ8iEKuipI7/CJkgB2RALGz+sXzZL9nRKnQoYVSHDTS2a3mxaasRZkV8MxRaUtbq6GBtciF9uhDZOA=="
|
"integrity": "sha512-l7cBiK3u4J6noRj/5bRjsdUywP+ITyBUK/UBJHSdEAXr0IkZDLy3gZjrWeO7gV81cZyfFQ+qtWBQzlsIlKsCzw=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts": {
|
||||||
"file": "adresses.js",
|
"file": "adresses.js",
|
||||||
|
|
@ -193,9 +193,9 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js"
|
"_index.DeCaB8sW.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-wxZc24uay8AJp/9gR77xSxP/1jxPqE0dwEIjJOSUSZ5iaZ0E+u98NkVDVnJjvf+k+vaBaDdyEUPJg/gJpWTFcw=="
|
"integrity": "sha512-MMxY7Qev3mDi/rNKwRhL+VvzA17YL7+/Ne2X/Gfr8UlhmDjnqN5WAeJmVFUQarUe5af7+XXYBS97jPTuhwxmwg=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-add-item.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-add-item.ts": {
|
||||||
"file": "cart-add-item.js",
|
"file": "cart-add-item.js",
|
||||||
|
|
@ -203,9 +203,36 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-add-item.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-add-item.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js"
|
"_index.DeCaB8sW.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-7nxF9KlbqvnjKgJRHy9gp6KYR9x6HIeYbekYRme7uD9zYI7ijvOworgbikKhh/VpyU0DMsxipMkIbN5aTywvVg=="
|
"integrity": "sha512-jtLTsorapki2SSs3gEQ4o/ElG1ecJQXOM8C9M8ropdjFYjLhnNTsRjOQN3JSxc7Fdm/6mvn9M2lRRFdliJ85CQ=="
|
||||||
|
},
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-apply-coupon.ts": {
|
||||||
|
"file": "cart-apply-coupon.js",
|
||||||
|
"name": "cart-apply-coupon",
|
||||||
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-apply-coupon.ts",
|
||||||
|
"isEntry": true,
|
||||||
|
"imports": [
|
||||||
|
"_index.DeCaB8sW.js"
|
||||||
|
],
|
||||||
|
"integrity": "sha512-BMCLu7o5txvpnrvMbaO+fCvx40S+B+1kFRa4zhJTip+tMfA8VGucuJVgSZOs1G7RFbKQKhk4Sxv0Djd5louYGA=="
|
||||||
|
},
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-coupons.ts": {
|
||||||
|
"file": "cart-coupons.js",
|
||||||
|
"name": "cart-coupons",
|
||||||
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-coupons.ts",
|
||||||
|
"isEntry": true,
|
||||||
|
"integrity": "sha512-kamZpV4ivpmgTZOvxlrFF28P97K9C2tlKIuLt2yYIUj40qbTrS1JZNn1WTEF+jiFvIVDJTt1zKrKJOD2ptDBvg=="
|
||||||
|
},
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-remove-coupon.ts": {
|
||||||
|
"file": "cart-remove-coupon.js",
|
||||||
|
"name": "cart-remove-coupon",
|
||||||
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-remove-coupon.ts",
|
||||||
|
"isEntry": true,
|
||||||
|
"imports": [
|
||||||
|
"_index.DeCaB8sW.js"
|
||||||
|
],
|
||||||
|
"integrity": "sha512-hRxsjUgQbfhkmW9NTopSXU+2JLiARm+iz6Ub09lTaqnvjPT28QUTrTRQ+g96SQlyvZl4Pxmr5qeevo4nRN1ZPw=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-remove-item.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-remove-item.ts": {
|
||||||
"file": "cart-remove-item.js",
|
"file": "cart-remove-item.js",
|
||||||
|
|
@ -213,9 +240,9 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-remove-item.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-remove-item.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js"
|
"_index.DeCaB8sW.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-Y9EkBSzy3+A3xo0eKBp6BMxerG5/WKC6KI8U/NcI5rqsTP3L/o70pj6YfhtjRT+KesOfNPdsTAy0mFVsLgWwrg=="
|
"integrity": "sha512-prpxKV2zTo++qCwxAXdHHnOR5PzaYKVZvZe0yYCGTlRaBHYHlnC1+5jfN9EKjsshwd+agH91mMOuVsM5q6Ptcw=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-customer.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-customer.ts": {
|
||||||
"file": "cart-update-customer.js",
|
"file": "cart-update-customer.js",
|
||||||
|
|
@ -223,10 +250,10 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-customer.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-customer.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts"
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-PivxAS9NMdYD9NUHNPvHA5e3DB7RByKN+Cg5tX4HDzSrMg2XNC7oCATNgFMn/hSpr5Eh0A84giqIJV+vt3d5zw=="
|
"integrity": "sha512-ioQUabvwDl6JWayPctjngWpjmb7BkIFnWcoAYVQjfeue1sfv8Aa7NXcTB8Bmmd2ZGm7nX2xur91I1DrYz0BnYQ=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-item.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-item.ts": {
|
||||||
"file": "cart-update-item.js",
|
"file": "cart-update-item.js",
|
||||||
|
|
@ -234,9 +261,9 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-item.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-item.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js"
|
"_index.DeCaB8sW.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-Jkl0iSGOukBIjOv+zEVDcUX/sUtfdyl6mJd+gXyjx7WbTy4KYYLv68BhZigLzOJptrWoCF08ajWAQ8BODiM19g=="
|
"integrity": "sha512-DqeR6ekRzBk1cWAlhFx25NBxMsulAEstDkb87ZZ8sPIjLlgwe5TfqBYegXclTC9Wg9cLK1VR6DHoWrNDDrUHpw=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart.ts": {
|
||||||
"file": "cart.js",
|
"file": "cart.js",
|
||||||
|
|
@ -244,12 +271,12 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/cart.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/cart.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts"
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-fwzj5jqgK8lTM+j1f1NkFdwhJVErJtKWyW9zJMV/1m9efxo0XHxY+OO+3Xkn0/ycHSni1bI1tCzVCMuTg6vpKQ=="
|
"integrity": "sha512-quTwNVIvYDgwjiQDgZQUc8usQML19ABUBTtLtSPFVD11yrfTKCe3qgnvjH4sy/8URUN/JChYhgxKA+6tf2GQHw=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts": {
|
||||||
"file": "couts-livraison.js",
|
"file": "couts-livraison.js",
|
||||||
|
|
@ -257,10 +284,10 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts"
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-EJLCLruWUYLwW+gIaOvchNjq46HFs1f3Xq7OacFEHvM23fYen4EMZbuN0LWhAxnIhQwIu2W4TPYU7IwXHu5Xng=="
|
"integrity": "sha512-zOIvFVeeme0okbWtPxAgYiJ9ApVZ3WqFRGm8pPeTivjgxwbVVb/f7bSbtvK3Wr1yUALE7wQXulTvFMpwO+vH1A=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/erreurs.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/erreurs.ts": {
|
||||||
"file": "erreurs2.js",
|
"file": "erreurs2.js",
|
||||||
|
|
@ -268,9 +295,9 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/erreurs.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/erreurs.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js"
|
"_index.DeCaB8sW.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-dowi5DfOrRfPTkwCskhvYFC81FPuTs+aGWQJ5S/jC37V9nT20vUfGgmT81arvPn6wpnNaHf9aVcEE+1+bctgdQ=="
|
"integrity": "sha512-0aovUwOkfcV+G3x1owksl5ILTHx7ER0ka0Af2eL0ZB7rj0kyWkQXpUP5MlerrMKrOPDUBmIqjJbVg6sMGMFvsA=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/products.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/products.ts": {
|
||||||
"file": "products3.js",
|
"file": "products3.js",
|
||||||
|
|
@ -278,22 +305,22 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/products.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/products.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/products.ts"
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/products.ts"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-EoP6Wq6Pv9atR1Rq38hxNLiwwjVeA87qZivbidmtMNlEQ3lc5Xv1GHGIhVKoiZp9YFo7r82ZSnI7UeyS3YOkSA=="
|
"integrity": "sha512-Trpy89hQymfheaW8dgJR4VhW5JAi/KPRC1RqCxmJFZUToqNqA7W2GAAIpaGGywMwwlVqmXndfTN5U0fpOCM3Tg=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/v3/orders.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/v3/orders.ts": {
|
||||||
"file": "orders2.js",
|
"file": "orders.js",
|
||||||
"name": "orders",
|
"name": "orders",
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/v3/orders.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/v3/orders.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/orders.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/orders.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts"
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-snLY2wshCn9hIGTa8fooyNqFsGIQBfQhsMTypG0HOfTlmUV2ib+ranc0q4lsEoHixrpSB2sD0qXNdHSt2kgFoA=="
|
"integrity": "sha512-Kre4n1ECvEQb4rJ2CSvaCfYQDiMPwseQAltQuaQ7bIgXfnRGCRXWZ+H8xK7hKGenaZQnSp8kVwZ2lcyGzSC4dw=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/v3/products.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/v3/products.ts": {
|
||||||
"file": "products.js",
|
"file": "products.js",
|
||||||
|
|
@ -301,10 +328,10 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/v3/products.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/v3/products.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/products.ts"
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/products.ts"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-rmvhLGUPYFJleUJIqCvt8xg4hHR74+yiQ0QPtleozfSgGOkZiV+WN/oRYd6MCHEGXXeKC2z5rA83EM7PdDLLBA=="
|
"integrity": "sha512-drUCjv7zIsJahz4nwVEcEEFS6McC4Jk/NVfabKHIajgdC6r/PpAhMT9Dv6udLFLODbu/hYSGxfnRAuyXSv4GJw=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts": {
|
||||||
"file": "messages2.js",
|
"file": "messages2.js",
|
||||||
|
|
@ -312,21 +339,21 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/cart.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/cart.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts"
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-rqsyrxdcmlk/Xwmam1mSpoWzBRKQz6Eb9hUTxD0qOsW7gaC/BDS009V0/9icF0lP+GTddWNfNIAiWPStLCTQww=="
|
"integrity": "sha512-JKw9KmQsaKjXeXDkKkxPWyLGP7os2etoHcOeei88t3+XbDgGddzVbAVFallljGaDLMRYDRhl81aCwFohyRe8qA=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/types/api/v3/orders.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/types/api/v3/orders.ts": {
|
||||||
"file": "orders.js",
|
"file": "orders3.js",
|
||||||
"name": "orders",
|
"name": "orders",
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/types/api/v3/orders.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/types/api/v3/orders.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"integrity": "sha512-FxX8RZIDDZuWNSNyFz9fYxNVJyRtwOZfK0KQ6c3Vn98d/Ovd3m+OjmjXXiYnENzH86EpLIuHjxc/RiUIVsAvDQ=="
|
"integrity": "sha512-nqCjj7B9DjVJS7/4WgLDt58w1LMfLMxDfutD7vY99PNX9rjdiF1ckCffcMuxCGureeEu8qw9RCRKMavMDEX2bw=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/types/api/v3/products.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/types/api/v3/products.ts": {
|
||||||
"file": "products4.js",
|
"file": "products4.js",
|
||||||
|
|
@ -355,10 +382,10 @@
|
||||||
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/validation.ts",
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/lib/validation.ts",
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"_Either.wHNxn7Os.js"
|
"_Either.wHNxn7Os.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-Wr3Pn/SgzL55B/UiVKszE14pueIbR2UK5ZQ+zQHUrv+QViOSm+Bk5RyNxEqZNdKX2P/lbWs9/QwGgj7AieVq5g=="
|
"integrity": "sha512-+JFwOCgnzY60Mc2eSWHulo7Pmg1WdcghpZICm82dY6cCnu9MfszbqTvAis8mH7lk0Jq0+FdWNXYMNdmoHzA3fg=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-bouton-panier.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-bouton-panier.ts": {
|
||||||
"file": "scripts-bouton-panier.js",
|
"file": "scripts-bouton-panier.js",
|
||||||
|
|
@ -375,14 +402,14 @@
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/erreurs.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/erreurs.ts",
|
||||||
"_exports.DT-46nyp.js",
|
"_exports.DT-46nyp.js",
|
||||||
"_Either.wHNxn7Os.js",
|
"_Either.wHNxn7Os.js",
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/cart.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/cart.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/adresses.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts"
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-CEgEh4Ysj8RFg6s3vYPH7p2w9Xfrpjx+Fk46y7Mx1L2ZuMnCYq8Lbo73cnIneA4afMZdaR2F+DXKduDNMV88mw=="
|
"integrity": "sha512-c2lPVLw4/BtVqdses0KHAGQL3WRcx6r78mek0FwrCD10x6Lrzg1VEt4c96Z/QX8gx0upzZt7XZwo+GfwQU/1sA=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-menu-categories.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-menu-categories.ts": {
|
||||||
"file": "scripts-menu-categories.js",
|
"file": "scripts-menu-categories.js",
|
||||||
|
|
@ -415,7 +442,7 @@
|
||||||
"_Either.wHNxn7Os.js",
|
"_Either.wHNxn7Os.js",
|
||||||
"_pipe.XPB0wEfw.js"
|
"_pipe.XPB0wEfw.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-S32/7dQE0D49gv3wprzFmUiQOC8GW67Xoemaa68wGE61zS0EYHTRmcCTagkTg+0uJw/knSv8if1Ms4XaytnClA=="
|
"integrity": "sha512-ur8F71PhcmJxjz5vOWwvpEDwgvtt3DIvUs70ZoHky1dc3366AxxW/eneNBhh2brWTxr+XB06JVVMDSVywZ0D8A=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-a-propos.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-a-propos.ts": {
|
||||||
"file": "scripts-page-a-propos.js",
|
"file": "scripts-page-a-propos.js",
|
||||||
|
|
@ -432,7 +459,7 @@
|
||||||
"_exports.DT-46nyp.js",
|
"_exports.DT-46nyp.js",
|
||||||
"_Either.wHNxn7Os.js"
|
"_Either.wHNxn7Os.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-WUcoEKVDXWekPdSMzpJepPYynA1j1zIK/QzETBesaXkFjNN0AG7sdSkFEtlhf4kcXh4GaSBZvPtuzBwPNbCx2Q=="
|
"integrity": "sha512-n5kzxn/FUDN7WZaghlqMv3n+7wgBbO5ntBQYGvtpO0f3maqwXSw16O5Kz0FPxQpif97Xgh8xdxL7SRWeUHkg8A=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-accueil.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-accueil.ts": {
|
||||||
"file": "scripts-page-accueil.js",
|
"file": "scripts-page-accueil.js",
|
||||||
|
|
@ -458,7 +485,7 @@
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CeK6pfoJ.js",
|
"_index.CeK6pfoJ.js",
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/api.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/api.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/dom.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/dom.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/dom.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/dom.ts",
|
||||||
|
|
@ -476,7 +503,23 @@
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/products.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/products.ts",
|
||||||
"_belt_Option-91f3b350.BKMoZFhU.js"
|
"_belt_Option-91f3b350.BKMoZFhU.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-F/ScBzgbN07v1YNg/j/T8BPeLoAP7aS3qA1C1wLQ/V7IVQjqV7GVWUqqDQczcg0Sh2xWgE1tBIkgzJMb8VZ1lA=="
|
"integrity": "sha512-UJ65bimSLn101pT4fvkq+ri0VXxmg9iZ/y66jq5XBmPLi2E788SZs/mtVaFVLKGCIyil64JSIH9J8dhFx0D1Ow=="
|
||||||
|
},
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-panier-code-promo.ts": {
|
||||||
|
"file": "scripts-page-panier-code-promo.js",
|
||||||
|
"name": "scripts-page-panier-code-promo",
|
||||||
|
"src": "web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-panier-code-promo.ts",
|
||||||
|
"isEntry": true,
|
||||||
|
"imports": [
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/dom.ts",
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/utils.ts",
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/dom.ts",
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/erreurs.ts",
|
||||||
|
"_exports.DT-46nyp.js",
|
||||||
|
"_Either.wHNxn7Os.js",
|
||||||
|
"_pipe.XPB0wEfw.js"
|
||||||
|
],
|
||||||
|
"integrity": "sha512-WgxyPzbqGfZbXTo1NrcaGULnyN53Ad2srjXoTRkx990EVtK5DcrPEP6BvA1YOc1p/vOfu8Ry8KpeTSl4blwXwg=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-panier.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-panier.ts": {
|
||||||
"file": "scripts-page-panier.js",
|
"file": "scripts-page-panier.js",
|
||||||
|
|
@ -485,7 +528,7 @@
|
||||||
"isEntry": true,
|
"isEntry": true,
|
||||||
"imports": [
|
"imports": [
|
||||||
"_index.CeK6pfoJ.js",
|
"_index.CeK6pfoJ.js",
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/api.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/api.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/dom.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/dom.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts",
|
||||||
|
|
@ -494,6 +537,8 @@
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/gardes.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/gardes.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/messages.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/messages.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/reseau.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/reseau.ts",
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-apply-coupon.ts",
|
||||||
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-remove-coupon.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-remove-item.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-remove-item.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-customer.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-customer.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-item.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/cart-update-item.ts",
|
||||||
|
|
@ -504,6 +549,7 @@
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/validation.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/validation.ts",
|
||||||
"_pipe.XPB0wEfw.js",
|
"_pipe.XPB0wEfw.js",
|
||||||
"_index-0eef19ec.CFsloYN6.js",
|
"_index-0eef19ec.CFsloYN6.js",
|
||||||
|
"_MaybeAsync.Ba-OfjWy.js",
|
||||||
"_Either.wHNxn7Os.js",
|
"_Either.wHNxn7Os.js",
|
||||||
"_exports.DT-46nyp.js",
|
"_exports.DT-46nyp.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
||||||
|
|
@ -513,7 +559,7 @@
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/orders.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/orders.ts",
|
||||||
"_belt_Option-91f3b350.BKMoZFhU.js"
|
"_belt_Option-91f3b350.BKMoZFhU.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-43e9x7ZGQl7cv+OHv91Gk55D7yWLIT+OimqniA+E+Ol3+yddsj8ez3xcDOIv0vZZVu0kZTby+LZ0mgnoed3wlQ=="
|
"integrity": "sha512-JT02QHHnBgQjwcB2dwaM08tKsQO3HaQLSmy1hkB4xxKuC92rBv2jBd6Hj2SBMTjch4H0270NPMC98esVTcET+g=="
|
||||||
},
|
},
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-produit.ts": {
|
"web/app/themes/haiku-atelier-2024/src/scripts/scripts-page-produit.ts": {
|
||||||
"file": "scripts-page-produit.js",
|
"file": "scripts-page-produit.js",
|
||||||
|
|
@ -537,7 +583,7 @@
|
||||||
"_index-0eef19ec.CFsloYN6.js",
|
"_index-0eef19ec.CFsloYN6.js",
|
||||||
"_Either.wHNxn7Os.js",
|
"_Either.wHNxn7Os.js",
|
||||||
"_exports.DT-46nyp.js",
|
"_exports.DT-46nyp.js",
|
||||||
"_index.CXGAS3st.js",
|
"_index.DeCaB8sW.js",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/constantes/messages.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/messages.ts",
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/erreurs.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/erreurs.ts",
|
||||||
|
|
@ -546,6 +592,6 @@
|
||||||
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts",
|
"web/app/themes/haiku-atelier-2024/src/scripts/lib/schemas/api/couts-livraison.ts",
|
||||||
"_belt_Option-91f3b350.BKMoZFhU.js"
|
"_belt_Option-91f3b350.BKMoZFhU.js"
|
||||||
],
|
],
|
||||||
"integrity": "sha512-eEzW7ukzpYsVTOkmJPO6vEnOefXhetRPh4+bkjdbf6nNL651Ms7o5zwip+6ZwtXpMxQeqDSRIV+M2LxGzxaDiQ=="
|
"integrity": "sha512-xezJYeBOyJhax3Kdcv6WJqp1RgZF7WG5wKf9XMjyTKsvUAlppMnhADz/xFhUEGJIAHIsvkKep4Z02GslZRN0oQ=="
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { o as object, s as string } from "./index.CXGAS3st.js";
|
import { o as object, s as string } from "./index.DeCaB8sW.js";
|
||||||
const WCStoreBillingAddressSchema = object({
|
const WCStoreBillingAddressSchema = object({
|
||||||
address_1: string(),
|
address_1: string(),
|
||||||
address_2: string(),
|
address_2: string(),
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,8 @@
|
||||||
const CHEMIN_API_REST = "wp-json";
|
const CHEMIN_API_REST = "wp-json";
|
||||||
const ROUTE_API_PANIER = `/${CHEMIN_API_REST}/wc/store/cart`;
|
const ROUTE_API_PANIER = `/${CHEMIN_API_REST}/wc/store/cart`;
|
||||||
const ROUTE_API_AJOUTE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/add-item`;
|
const ROUTE_API_AJOUTE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/add-item`;
|
||||||
|
const ROUTE_API_APPLIQUE_COUPON = `/${CHEMIN_API_REST}/wc/store/cart/apply-coupon`;
|
||||||
|
const ROUTE_API_RETIRE_COUPON = `/${CHEMIN_API_REST}/wc/store/cart/remove-coupon`;
|
||||||
const ROUTE_API_RETIRE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/remove-item`;
|
const ROUTE_API_RETIRE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/remove-item`;
|
||||||
const ROUTE_API_MAJ_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/update-item`;
|
const ROUTE_API_MAJ_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/update-item`;
|
||||||
const ROUTE_API_MAJ_CLIENT = `/${CHEMIN_API_REST}/wc/store/cart/update-customer`;
|
const ROUTE_API_MAJ_CLIENT = `/${CHEMIN_API_REST}/wc/store/cart/update-customer`;
|
||||||
|
|
@ -16,9 +18,11 @@ export {
|
||||||
ROUTE_API_MAJ_ARTICLE_PANIER as b,
|
ROUTE_API_MAJ_ARTICLE_PANIER as b,
|
||||||
ROUTE_API_MAJ_CLIENT as c,
|
ROUTE_API_MAJ_CLIENT as c,
|
||||||
ROUTE_API_NOUVELLE_COMMANDES as d,
|
ROUTE_API_NOUVELLE_COMMANDES as d,
|
||||||
ROUTE_API_AJOUTE_ARTICLE_PANIER as e,
|
ROUTE_API_RETIRE_COUPON as e,
|
||||||
ROUTE_API_PANIER as f,
|
ROUTE_API_APPLIQUE_COUPON as f,
|
||||||
ENTETE_GLITCHTIP_RETRY_AFTER as g,
|
ROUTE_API_AJOUTE_ARTICLE_PANIER as g,
|
||||||
ENTETE_GLITCHTIP_RATE_LIMITS as h
|
ROUTE_API_PANIER as h,
|
||||||
|
ENTETE_GLITCHTIP_RETRY_AFTER as i,
|
||||||
|
ENTETE_GLITCHTIP_RATE_LIMITS as j
|
||||||
};
|
};
|
||||||
//# sourceMappingURL=api.js.map
|
//# sourceMappingURL=api.js.map
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
{"version":3,"file":"api.js","sources":["../../src/scripts/constantes/api.ts"],"sourcesContent":["// Chemins et Routes pour l'API WordPress\nexport const CHEMIN_API_REST = \"wp-json\";\nexport const ROUTE_API_PANIER = `/${CHEMIN_API_REST}/wc/store/cart`;\nexport const ROUTE_API_AJOUTE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/add-item`;\nexport const ROUTE_API_RETIRE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/remove-item`;\nexport const ROUTE_API_MAJ_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/update-item`;\nexport const ROUTE_API_MAJ_CLIENT = `/${CHEMIN_API_REST}/wc/store/cart/update-customer`;\nexport const ROUTE_API_PRODUITS = `/${CHEMIN_API_REST}/wc/store/products`;\nexport const ROUTE_API_NOUVELLE_PRODUCTS = `/${CHEMIN_API_REST}/wc/v3/products`;\nexport const ROUTE_API_NOUVELLE_COMMANDES = `/${CHEMIN_API_REST}/wc/v3/orders`;\n\n// En-têtes\nexport const ENTETE_WC_NONCE = \"Nonce\";\nexport const ENTETE_GLITCHTIP_RETRY_AFTER = \"retry-after\";\nexport const ENTETE_GLITCHTIP_RATE_LIMITS = \"x-sentry-rate-limits\";\n"],"names":[],"mappings":"AACO,MAAM,kBAAkB;AAClB,MAAA,mBAAmB,IAAI,eAAe;AACtC,MAAA,kCAAkC,IAAI,eAAe;AACrD,MAAA,kCAAkC,IAAI,eAAe;AACrD,MAAA,+BAA+B,IAAI,eAAe;AAClD,MAAA,uBAAuB,IAAI,eAAe;AAE1C,MAAA,8BAA8B,IAAI,eAAe;AACjD,MAAA,+BAA+B,IAAI,eAAe;AAGxD,MAAM,kBAAkB;AACxB,MAAM,+BAA+B;AACrC,MAAM,+BAA+B;"}
|
{"version":3,"file":"api.js","sources":["../../src/scripts/constantes/api.ts"],"sourcesContent":["// Chemins et Routes pour l'API WordPress\nexport const CHEMIN_API_REST = \"wp-json\";\nexport const ROUTE_API_PANIER = `/${CHEMIN_API_REST}/wc/store/cart`;\nexport const ROUTE_API_AJOUTE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/add-item`;\nexport const ROUTE_API_APPLIQUE_COUPON = `/${CHEMIN_API_REST}/wc/store/cart/apply-coupon`;\nexport const ROUTE_API_RETIRE_COUPON = `/${CHEMIN_API_REST}/wc/store/cart/remove-coupon`;\nexport const ROUTE_API_COUPONS = `/${CHEMIN_API_REST}/wc/store/cart/coupons`;\nexport const ROUTE_API_RETIRE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/remove-item`;\nexport const ROUTE_API_MAJ_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/update-item`;\nexport const ROUTE_API_MAJ_CLIENT = `/${CHEMIN_API_REST}/wc/store/cart/update-customer`;\nexport const ROUTE_API_PRODUITS = `/${CHEMIN_API_REST}/wc/store/products`;\nexport const ROUTE_API_NOUVELLE_PRODUCTS = `/${CHEMIN_API_REST}/wc/v3/products`;\nexport const ROUTE_API_NOUVELLE_COMMANDES = `/${CHEMIN_API_REST}/wc/v3/orders`;\n\n// En-têtes\nexport const ENTETE_WC_NONCE = \"Nonce\";\nexport const ENTETE_GLITCHTIP_RETRY_AFTER = \"retry-after\";\nexport const ENTETE_GLITCHTIP_RATE_LIMITS = \"x-sentry-rate-limits\";\n"],"names":[],"mappings":"AACO,MAAM,kBAAkB;AAClB,MAAA,mBAAmB,IAAI,eAAe;AACtC,MAAA,kCAAkC,IAAI,eAAe;AACrD,MAAA,4BAA4B,IAAI,eAAe;AAC/C,MAAA,0BAA0B,IAAI,eAAe;AAE7C,MAAA,kCAAkC,IAAI,eAAe;AACrD,MAAA,+BAA+B,IAAI,eAAe;AAClD,MAAA,uBAAuB,IAAI,eAAe;AAE1C,MAAA,8BAA8B,IAAI,eAAe;AACjD,MAAA,+BAA+B,IAAI,eAAe;AAGxD,MAAM,kBAAkB;AACxB,MAAM,+BAA+B;AACrC,MAAM,+BAA+B;"}
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { o as object, c as optional, b as array, s as string, n as number } from "./index.CXGAS3st.js";
|
import { o as object, c as optional, b as array, s as string, n as number } from "./index.DeCaB8sW.js";
|
||||||
const WCStoreCartAddItemArgsItemsSchema = object({
|
const WCStoreCartAddItemArgsItemsSchema = object({
|
||||||
/** Variation attribute name. */
|
/** Variation attribute name. */
|
||||||
attribute: string(),
|
attribute: string(),
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,9 @@
|
||||||
|
import { o as object, c as optional, s as string } from "./index.DeCaB8sW.js";
|
||||||
|
const WCStoreCartApplyCouponArgsSchema = object({
|
||||||
|
/** Unique identifier for the coupon within the basket */
|
||||||
|
code: optional(string())
|
||||||
|
});
|
||||||
|
export {
|
||||||
|
WCStoreCartApplyCouponArgsSchema as W
|
||||||
|
};
|
||||||
|
//# sourceMappingURL=cart-apply-coupon.js.map
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"cart-apply-coupon.js","sources":["../../src/scripts/lib/schemas/api/cart-apply-coupon.ts"],"sourcesContent":["import * as v from \"valibot\";\n\nexport const WCStoreCartApplyCouponArgsSchema = v.object({\n /** Unique identifier for the coupon within the basket */\n code: v.optional(v.string()),\n});\n"],"names":["v.object","v.optional","v.string"],"mappings":";AAEa,MAAA,mCAAmCA,OAAS;AAAA;AAAA,EAEvD,MAAMC,SAAWC,OAAU,CAAA;AAC7B,CAAC;"}
|
||||||
|
|
@ -0,0 +1,2 @@
|
||||||
|
|
||||||
|
//# sourceMappingURL=cart-coupons.js.map
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"cart-coupons.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
||||||
|
|
@ -0,0 +1,9 @@
|
||||||
|
import { o as object, c as optional, s as string } from "./index.DeCaB8sW.js";
|
||||||
|
const WCStoreCartRemoveCouponArgsSchema = object({
|
||||||
|
/** Unique identifier for the coupon within the basket */
|
||||||
|
code: optional(string())
|
||||||
|
});
|
||||||
|
export {
|
||||||
|
WCStoreCartRemoveCouponArgsSchema as W
|
||||||
|
};
|
||||||
|
//# sourceMappingURL=cart-remove-coupon.js.map
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"cart-remove-coupon.js","sources":["../../src/scripts/lib/schemas/api/cart-remove-coupon.ts"],"sourcesContent":["import * as v from \"valibot\";\n\nexport const WCStoreCartRemoveCouponArgsSchema = v.object({\n /** Unique identifier for the coupon within the basket */\n code: v.optional(v.string()),\n});\n"],"names":["v.object","v.optional","v.string"],"mappings":";AAEa,MAAA,oCAAoCA,OAAS;AAAA;AAAA,EAExD,MAAMC,SAAWC,OAAU,CAAA;AAC7B,CAAC;"}
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { o as object, s as string } from "./index.CXGAS3st.js";
|
import { o as object, s as string } from "./index.DeCaB8sW.js";
|
||||||
const WCStoreCartRemoveItemArgsSchema = object({
|
const WCStoreCartRemoveItemArgsSchema = object({
|
||||||
/** Unique identifier (key) for the basket item. */
|
/** Unique identifier (key) for the basket item. */
|
||||||
key: string()
|
key: string()
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { o as object, c as optional } from "./index.CXGAS3st.js";
|
import { o as object, c as optional } from "./index.DeCaB8sW.js";
|
||||||
import { W as WCStoreShippingAddressSchema, a as WCStoreBillingAddressSchema } from "./adresses.js";
|
import { W as WCStoreShippingAddressSchema, a as WCStoreBillingAddressSchema } from "./adresses.js";
|
||||||
const WCStoreCartUpdateCustomerArgsSchema = object({
|
const WCStoreCartUpdateCustomerArgsSchema = object({
|
||||||
billing_address: optional(WCStoreBillingAddressSchema),
|
billing_address: optional(WCStoreBillingAddressSchema),
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { o as object, a as pipe, m as minValue, n as number, s as string } from "./index.CXGAS3st.js";
|
import { o as object, a as pipe, k as minValue, n as number, s as string } from "./index.DeCaB8sW.js";
|
||||||
const WCStoreCartUpdateItemArgsSchema = object({
|
const WCStoreCartUpdateItemArgsSchema = object({
|
||||||
/** Unique identifier (key) for the basket item to update. */
|
/** Unique identifier (key) for the basket item to update. */
|
||||||
key: string(),
|
key: string(),
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { o as object, b as array, u as unknown, s as string, n as number, d as boolean, a as pipe, f as url, g as union, h as null_, e as enum_, i as integer } from "./index.CXGAS3st.js";
|
import { o as object, b as array, u as unknown, s as string, n as number, d as boolean, a as pipe, f as url, g as union, h as null_, e as enum_, i as integer } from "./index.DeCaB8sW.js";
|
||||||
import { C as CATALOG_VISIBILITIES } from "./cart2.js";
|
import { C as CATALOG_VISIBILITIES } from "./cart2.js";
|
||||||
import { W as WCStoreShippingAddressSchema, a as WCStoreBillingAddressSchema } from "./adresses.js";
|
import { W as WCStoreShippingAddressSchema, a as WCStoreBillingAddressSchema } from "./adresses.js";
|
||||||
import { a as WCStoreShippingRateSchema } from "./couts-livraison.js";
|
import { a as WCStoreShippingRateSchema } from "./couts-livraison.js";
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { o as object, b as array, s as string, d as boolean, u as unknown, n as number, j as omit } from "./index.CXGAS3st.js";
|
import { o as object, b as array, s as string, d as boolean, u as unknown, n as number, j as omit } from "./index.DeCaB8sW.js";
|
||||||
import { W as WCStoreShippingAddressSchema } from "./adresses.js";
|
import { W as WCStoreShippingAddressSchema } from "./adresses.js";
|
||||||
const WCStoreShippingRateItemSchema = object({
|
const WCStoreShippingRateItemSchema = object({
|
||||||
key: string(),
|
key: string(),
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,7 @@ const ATTRIBUT_ID_ENSEMBLE_EPINGLE_BOITE = "data-id-ensemble-epingle-boite";
|
||||||
const ATTRIBUT_ENSEMBLE_EPINGLE_BOITE_ACTIF = "data-ensemble-epingle-boite-actif";
|
const ATTRIBUT_ENSEMBLE_EPINGLE_BOITE_ACTIF = "data-ensemble-epingle-boite-actif";
|
||||||
const ATTRIBUT_INDEX_IMAGE_ACTIVE = "data-index-image-active";
|
const ATTRIBUT_INDEX_IMAGE_ACTIVE = "data-index-image-active";
|
||||||
const ATTRIBUT_PRIX = "data-prix";
|
const ATTRIBUT_PRIX = "data-prix";
|
||||||
|
const ATTRIBUT_CODE_PROMO_PRESENT = "data-code-promo-present";
|
||||||
const SELECTEUR_BOUTON_MENU_MOBILE = "#bouton-menu-mobile";
|
const SELECTEUR_BOUTON_MENU_MOBILE = "#bouton-menu-mobile";
|
||||||
const SELECTEUR_BOUTON_PANIER = ".compte-panier a[rel='cart']";
|
const SELECTEUR_BOUTON_PANIER = ".compte-panier a[rel='cart']";
|
||||||
const SELECTEUR_MENU_MOBILE = "#menu-mobile";
|
const SELECTEUR_MENU_MOBILE = "#menu-mobile";
|
||||||
|
|
@ -31,12 +32,17 @@ const SELECTEUR_PRIX_LIGNE_PANIER = ".detail-produit__nom-prix span";
|
||||||
const SELECTEUR_SOUS_TOTAL_PRODUITS = "#panneau-panier #sous-total-produits strong";
|
const SELECTEUR_SOUS_TOTAL_PRODUITS = "#panneau-panier #sous-total-produits strong";
|
||||||
const SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT = "#panneau-panier #sous-total-livraison strong";
|
const SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT = "#panneau-panier #sous-total-livraison strong";
|
||||||
const SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE = "#panneau-panier #sous-total-livraison span";
|
const SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE = "#panneau-panier #sous-total-livraison span";
|
||||||
|
const SELECTEUR_TOTAL_REDUCTION = "#panneau-panier #sous-total-reduction";
|
||||||
|
const SELECTEUR_TOTAL_REDUCTION_VALEUR = "#panneau-panier #sous-total-reduction strong";
|
||||||
const SELECTEUR_TOTAL_PANIER = "#panneau-panier .panneau__pied-de-page p span";
|
const SELECTEUR_TOTAL_PANIER = "#panneau-panier .panneau__pied-de-page p span";
|
||||||
const SELECTEUR_BOUTON_SEPARATION_ADRESSES = "#separation-adresses";
|
const SELECTEUR_BOUTON_SEPARATION_ADRESSES = "#separation-adresses";
|
||||||
const SELECTEUR_FORMULAIRE_PANIER = "#panneau-informations-client form";
|
const SELECTEUR_FORMULAIRE_PANIER = "#panneau-informations-client form";
|
||||||
const SELECTEUR_FORMULAIRE_FACTURATION = "#panneau-informations-client .panneau__formulaires__facturation";
|
const SELECTEUR_FORMULAIRE_FACTURATION = "#panneau-informations-client .panneau__formulaires__facturation";
|
||||||
const SELECTEUR_BOUTON_ACTIONS_FORMULAIRE = "#panneau-informations-client .panneau__pied-de-page button";
|
const SELECTEUR_BOUTON_ACTIONS_FORMULAIRE = "#panneau-informations-client .panneau__pied-de-page button";
|
||||||
const SELECTEUR_INSTRUCTIONS_CLIENT = "#panneau-panier #instructions-client";
|
const SELECTEUR_INSTRUCTIONS_CLIENT = "#panneau-panier #instructions-client";
|
||||||
|
const SELECTEUR_ENSEMBLE_CODE_PROMO = "#panneau-panier #ensemble-code-promo";
|
||||||
|
const SELECTEUR_CHAMP_CODE_PROMO = "#panneau-panier #champ-code-promo";
|
||||||
|
const SELECTEUR_BOUTON_CODE_PROMO = "#panneau-panier #bouton-code-promo";
|
||||||
const SELECTEUR_CONTENEUR_STORYTELLING = ".storytelling";
|
const SELECTEUR_CONTENEUR_STORYTELLING = ".storytelling";
|
||||||
const SELECTEUR_IMAGES_STORYTELLING = ".storytelling__image";
|
const SELECTEUR_IMAGES_STORYTELLING = ".storytelling__image";
|
||||||
const SELECTEUR_GRILLE_PRODUITS = "#page-boutique .grille-produits";
|
const SELECTEUR_GRILLE_PRODUITS = "#page-boutique .grille-produits";
|
||||||
|
|
@ -55,36 +61,42 @@ const SELECTEUR_IMAGE_COLONNE_GAUCHE = ".colonne-gauche img";
|
||||||
const SELECTEUR_IMAGES_COLONNE_DROITE = ".colonne-droite img";
|
const SELECTEUR_IMAGES_COLONNE_DROITE = ".colonne-droite img";
|
||||||
const SELECTEUR_PRIX_PRODUIT = ".selecteur-produit__prix";
|
const SELECTEUR_PRIX_PRODUIT = ".selecteur-produit__prix";
|
||||||
export {
|
export {
|
||||||
CLASS_BOUTON_FERMETURE_BOITE_TEXTE as $,
|
ATTRIBUT_MENU_MOBILE_ACTIVE as $,
|
||||||
ATTRIBUT_CONTIENT_ARTICLES as A,
|
ATTRIBUT_CONTIENT_ARTICLES as A,
|
||||||
SELECTEUR_BOUTON_SUPPRESSION_PANIER as B,
|
SELECTEUR_BOUTON_ACTIONS_FORMULAIRE as B,
|
||||||
ATTRIBUT_DESACTIVE as C,
|
ATTRIBUT_CLE_PANIER as C,
|
||||||
SELECTEUR_PRIX_LIGNE_PANIER as D,
|
SELECTEUR_BOUTON_SOUSTRACTION_QUANTITE as D,
|
||||||
SELECTEUR_BOUTON_AJOUT_PANIER as E,
|
SELECTEUR_CHAMP_QUANTITE_LIGNE_PANIER as E,
|
||||||
SELECTEUR_SELECTEUR_QUANTITE as F,
|
SELECTEUR_BOUTON_ADDITION_QUANTITE as F,
|
||||||
SELECTEUR_PRIX_PRODUIT as G,
|
SELECTEUR_BOUTON_SUPPRESSION_PANIER as G,
|
||||||
SELECTEUR_LIENS_ONGLETS as H,
|
ATTRIBUT_DESACTIVE as H,
|
||||||
SELECTEUR_SECTIONS_CONTENUS as I,
|
SELECTEUR_PRIX_LIGNE_PANIER as I,
|
||||||
ATTRIBUT_ARIA_SELECTED as J,
|
ATTRIBUT_CODE_PROMO_PRESENT as J,
|
||||||
ATTRIBUT_PRIX as K,
|
SELECTEUR_BOUTON_AJOUT_PANIER as K,
|
||||||
SELECTEUR_CONTENEUR_FLECHES_DEFILEMENT as L,
|
SELECTEUR_SELECTEUR_QUANTITE as L,
|
||||||
SELECTEUR_FLECHE_DEFILEMENT_GAUCHE as M,
|
SELECTEUR_PRIX_PRODUIT as M,
|
||||||
SELECTEUR_FLECHE_DEFILEMENT_DROITE as N,
|
SELECTEUR_LIENS_ONGLETS as N,
|
||||||
SELECTEUR_PHOTOS_PRODUIT as O,
|
SELECTEUR_SECTIONS_CONTENUS as O,
|
||||||
SELECTEUR_IMAGE_COLONNE_GAUCHE as P,
|
ATTRIBUT_ARIA_SELECTED as P,
|
||||||
SELECTEUR_IMAGES_COLONNE_DROITE as Q,
|
ATTRIBUT_PRIX as Q,
|
||||||
ATTRIBUT_INDEX_IMAGE_ACTIVE as R,
|
SELECTEUR_CONTENEUR_FLECHES_DEFILEMENT as R,
|
||||||
SELECTEUR_BOUTON_PANIER as S,
|
SELECTEUR_BOUTON_PANIER as S,
|
||||||
SELECTEUR_BOUTON_MENU_MOBILE as T,
|
SELECTEUR_FLECHE_DEFILEMENT_GAUCHE as T,
|
||||||
SELECTEUR_MENU_MOBILE as U,
|
SELECTEUR_FLECHE_DEFILEMENT_DROITE as U,
|
||||||
ATTRIBUT_MENU_MOBILE_ACTIVE as V,
|
SELECTEUR_PHOTOS_PRODUIT as V,
|
||||||
SELECTEUR_CONTENEUR_STORYTELLING_A_PROPOS as W,
|
SELECTEUR_IMAGE_COLONNE_GAUCHE as W,
|
||||||
SELECTEUR_EPINGLE as X,
|
SELECTEUR_IMAGES_COLONNE_DROITE as X,
|
||||||
SELECTEUR_BOITE_TEXTE as Y,
|
ATTRIBUT_INDEX_IMAGE_ACTIVE as Y,
|
||||||
ATTRIBUT_ID_ENSEMBLE_EPINGLE_BOITE as Z,
|
SELECTEUR_BOUTON_MENU_MOBILE as Z,
|
||||||
ATTRIBUT_ENSEMBLE_EPINGLE_BOITE_ACTIF as _,
|
SELECTEUR_MENU_MOBILE as _,
|
||||||
SELECTEUR_MENU_CATEGORIES_PRODUITS as a,
|
SELECTEUR_MENU_CATEGORIES_PRODUITS as a,
|
||||||
CLASS_EPINGLE as a0,
|
SELECTEUR_CONTENEUR_STORYTELLING_A_PROPOS as a0,
|
||||||
|
SELECTEUR_EPINGLE as a1,
|
||||||
|
SELECTEUR_BOITE_TEXTE as a2,
|
||||||
|
ATTRIBUT_ID_ENSEMBLE_EPINGLE_BOITE as a3,
|
||||||
|
ATTRIBUT_ENSEMBLE_EPINGLE_BOITE_ACTIF as a4,
|
||||||
|
CLASS_BOUTON_FERMETURE_BOITE_TEXTE as a5,
|
||||||
|
CLASS_EPINGLE as a6,
|
||||||
SELECTEUR_ENTREE_MENU_CATEGORIES_PRODUITS as b,
|
SELECTEUR_ENTREE_MENU_CATEGORIES_PRODUITS as b,
|
||||||
SELECTEUR_CONTENEUR_STORYTELLING as c,
|
SELECTEUR_CONTENEUR_STORYTELLING as c,
|
||||||
SELECTEUR_IMAGES_STORYTELLING as d,
|
SELECTEUR_IMAGES_STORYTELLING as d,
|
||||||
|
|
@ -95,20 +107,20 @@ export {
|
||||||
ATTRIBUT_ID_CATEGORIE_PRODUITS as i,
|
ATTRIBUT_ID_CATEGORIE_PRODUITS as i,
|
||||||
ATTRIBUT_PAGE as j,
|
ATTRIBUT_PAGE as j,
|
||||||
ATTRIBUT_HIDDEN as k,
|
ATTRIBUT_HIDDEN as k,
|
||||||
SELECTEUR_ENTREES_PANIER as l,
|
SELECTEUR_BOUTON_CODE_PROMO as l,
|
||||||
SELECTEUR_CONTENEUR_PANIER as m,
|
SELECTEUR_CHAMP_CODE_PROMO as m,
|
||||||
SELECTEUR_SOUS_TOTAL_PRODUITS as n,
|
SELECTEUR_ENSEMBLE_CODE_PROMO as n,
|
||||||
SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT as o,
|
SELECTEUR_TOTAL_REDUCTION_VALEUR as o,
|
||||||
SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE as p,
|
SELECTEUR_TOTAL_REDUCTION as p,
|
||||||
SELECTEUR_INSTRUCTIONS_CLIENT as q,
|
SELECTEUR_ENTREES_PANIER as q,
|
||||||
SELECTEUR_TOTAL_PANIER as r,
|
SELECTEUR_CONTENEUR_PANIER as r,
|
||||||
SELECTEUR_BOUTON_SEPARATION_ADRESSES as s,
|
SELECTEUR_SOUS_TOTAL_PRODUITS as s,
|
||||||
SELECTEUR_FORMULAIRE_PANIER as t,
|
SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT as t,
|
||||||
SELECTEUR_FORMULAIRE_FACTURATION as u,
|
SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE as u,
|
||||||
SELECTEUR_BOUTON_ACTIONS_FORMULAIRE as v,
|
SELECTEUR_INSTRUCTIONS_CLIENT as v,
|
||||||
ATTRIBUT_CLE_PANIER as w,
|
SELECTEUR_TOTAL_PANIER as w,
|
||||||
SELECTEUR_BOUTON_SOUSTRACTION_QUANTITE as x,
|
SELECTEUR_BOUTON_SEPARATION_ADRESSES as x,
|
||||||
SELECTEUR_CHAMP_QUANTITE_LIGNE_PANIER as y,
|
SELECTEUR_FORMULAIRE_PANIER as y,
|
||||||
SELECTEUR_BOUTON_ADDITION_QUANTITE as z
|
SELECTEUR_FORMULAIRE_FACTURATION as z
|
||||||
};
|
};
|
||||||
//# sourceMappingURL=dom.js.map
|
//# sourceMappingURL=dom.js.map
|
||||||
|
|
|
||||||
|
|
@ -72,6 +72,7 @@ const reporteEtLeveErreur = (erreur) => {
|
||||||
export {
|
export {
|
||||||
CleNonTrouveError as C,
|
CleNonTrouveError as C,
|
||||||
ErreurInconnue as E,
|
ErreurInconnue as E,
|
||||||
|
ServerError as S,
|
||||||
leveErreur as a,
|
leveErreur as a,
|
||||||
leveBadRequestError as b,
|
leveBadRequestError as b,
|
||||||
leveUnauthorizedError as c,
|
leveUnauthorizedError as c,
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { l as is, o as object, n as number, s as string } from "./index.CXGAS3st.js";
|
import { l as is, o as object, n as number, s as string } from "./index.DeCaB8sW.js";
|
||||||
const WCErrorBodySchema = object({
|
const WCErrorBodySchema = object({
|
||||||
code: string(),
|
code: string(),
|
||||||
data: object({
|
data: object({
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { g as ENTETE_GLITCHTIP_RETRY_AFTER, h as ENTETE_GLITCHTIP_RATE_LIMITS } from "./api.js";
|
import { i as ENTETE_GLITCHTIP_RETRY_AFTER, j as ENTETE_GLITCHTIP_RATE_LIMITS } from "./api.js";
|
||||||
import { i as isInstanceOf, t as truncate, a as consoleSandbox, D as DEBUG_BUILD$1, l as logger, g as getFunctionName, G as GLOBAL_OBJ, C as CONSOLE_LEVELS, f as fill, o as originalConsoleMethods, b as timestampInSeconds, d as isError, e as addNonEnumerableProperty, S as SyncPromise, r as resolvedSyncPromise, h as rejectedSyncPromise, j as dropUndefinedKeys, n as normalize, k as dateTimestampInSeconds, m as DEBUG_BUILD$2, u as urlEncode, p as uuid4, q as checkOrSetAlreadyCaught, s as isPrimitive, v as isParameterizedString, w as updateSession, x as prepareEvent, y as getDynamicSamplingContextFromClient, z as getIsolationScope, A as isThenable, B as isPlainObject, E as SDK_VERSION, F as getClient, H as getOriginalFunction, I as getFramesFromEvent, J as isErrorEvent$1, K as isDOMError, L as isDOMException, M as addExceptionTypeValue, N as isEvent, O as normalizeToSize, P as extractExceptionKeysForMessage, Q as addExceptionMechanism, R as isString, T as createStackParser, U as UNKNOWN_FUNCTION, V as safeJoin, W as htmlTreeAsString, X as getEventDescription, Y as getComponentName, Z as getLocationHref, _ as captureEvent, $ as getCurrentScope } from "./exports.DT-46nyp.js";
|
import { i as isInstanceOf, t as truncate, a as consoleSandbox, D as DEBUG_BUILD$1, l as logger, g as getFunctionName, G as GLOBAL_OBJ, C as CONSOLE_LEVELS, f as fill, o as originalConsoleMethods, b as timestampInSeconds, d as isError, e as addNonEnumerableProperty, S as SyncPromise, r as resolvedSyncPromise, h as rejectedSyncPromise, j as dropUndefinedKeys, n as normalize, k as dateTimestampInSeconds, m as DEBUG_BUILD$2, u as urlEncode, p as uuid4, q as checkOrSetAlreadyCaught, s as isPrimitive, v as isParameterizedString, w as updateSession, x as prepareEvent, y as getDynamicSamplingContextFromClient, z as getIsolationScope, A as isThenable, B as isPlainObject, E as SDK_VERSION, F as getClient, H as getOriginalFunction, I as getFramesFromEvent, J as isErrorEvent$1, K as isDOMError, L as isDOMException, M as addExceptionTypeValue, N as isEvent, O as normalizeToSize, P as extractExceptionKeysForMessage, Q as addExceptionMechanism, R as isString, T as createStackParser, U as UNKNOWN_FUNCTION, V as safeJoin, W as htmlTreeAsString, X as getEventDescription, Y as getComponentName, Z as getLocationHref, _ as captureEvent, $ as getCurrentScope } from "./exports.DT-46nyp.js";
|
||||||
import { p as pipe } from "./pipe.XPB0wEfw.js";
|
import { p as pipe } from "./pipe.XPB0wEfw.js";
|
||||||
function applyAggregateErrorsToEvent(exceptionFromErrorImplementation, parser, maxValueLimit = 250, key, limit, event, hint) {
|
function applyAggregateErrorsToEvent(exceptionFromErrorImplementation, parser, maxValueLimit = 250, key, limit, event, hint) {
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { f as ROUTE_API_PANIER, E as ENTETE_WC_NONCE } from "./api.js";
|
import { h as ROUTE_API_PANIER, E as ENTETE_WC_NONCE } from "./api.js";
|
||||||
import { E as EitherAsync } from "./MaybeAsync.Ba-OfjWy.js";
|
import { E as EitherAsync } from "./MaybeAsync.Ba-OfjWy.js";
|
||||||
import { r as right, l as left } from "./Either.wHNxn7Os.js";
|
import { r as right, l as left } from "./Either.wHNxn7Os.js";
|
||||||
const ETATS = _etats;
|
const ETATS = _etats;
|
||||||
|
|
|
||||||
|
|
@ -608,9 +608,9 @@ export {
|
||||||
null_ as h,
|
null_ as h,
|
||||||
integer as i,
|
integer as i,
|
||||||
omit as j,
|
omit as j,
|
||||||
maxValue as k,
|
minValue as k,
|
||||||
is as l,
|
is as l,
|
||||||
minValue as m,
|
maxValue as m,
|
||||||
number as n,
|
number as n,
|
||||||
object as o,
|
object as o,
|
||||||
parse as p,
|
parse as p,
|
||||||
|
|
@ -618,4 +618,4 @@ export {
|
||||||
unknown as u,
|
unknown as u,
|
||||||
value as v
|
value as v
|
||||||
};
|
};
|
||||||
//# sourceMappingURL=index.CXGAS3st.js.map
|
//# sourceMappingURL=index.DeCaB8sW.js.map
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { p as parse } from "./index.CXGAS3st.js";
|
import { p as parse } from "./index.DeCaB8sW.js";
|
||||||
import { N as NOM_CANAL_BOUTON_PANIER, T as TYPES_MESSAGES, a as NOM_CANAL_CONTENU_PANIER } from "./messages3.js";
|
import { N as NOM_CANAL_BOUTON_PANIER, T as TYPES_MESSAGES, a as NOM_CANAL_CONTENU_PANIER } from "./messages3.js";
|
||||||
import { r as reporteErreur } from "./erreurs.js";
|
import { r as reporteErreur } from "./erreurs.js";
|
||||||
import { M as MessageMajBoutonPanierSchema, a as MessageMajContenuPanierSchema } from "./messages2.js";
|
import { M as MessageMajBoutonPanierSchema, a as MessageMajContenuPanierSchema } from "./messages2.js";
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { e as enum_, o as object, a as pipe, v as value, s as string, n as number, b as array } from "./index.CXGAS3st.js";
|
import { e as enum_, o as object, a as pipe, v as value, s as string, n as number, b as array } from "./index.DeCaB8sW.js";
|
||||||
import { T as TYPES_MESSAGES } from "./messages3.js";
|
import { T as TYPES_MESSAGES } from "./messages3.js";
|
||||||
import { a as WCStoreCartItemSchema } from "./cart.js";
|
import { a as WCStoreCartItemSchema } from "./cart.js";
|
||||||
import "./cart2.js";
|
import "./cart2.js";
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1,162 @@
|
||||||
|
import { o as object, s as string, b as array, a as pipe, i as integer, n as number, e as enum_, u as unknown, g as union, c as optional, h as null_, d as boolean } from "./index.DeCaB8sW.js";
|
||||||
|
import { T as TAX_STATUSES, O as ORDER_STATUSES } from "./orders2.js";
|
||||||
|
import { W as WCStoreShippingAddressSchema, a as WCStoreBillingAddressSchema } from "./adresses.js";
|
||||||
|
const WCV3OrdersCouponLineMetaDataSchema = object({
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
key: string(),
|
||||||
|
value: unknown()
|
||||||
|
});
|
||||||
|
const WCV3OrdersCouponLineSchema = object({
|
||||||
|
code: string(),
|
||||||
|
discount: string(),
|
||||||
|
discount_tax: string(),
|
||||||
|
discount_type: string(),
|
||||||
|
free_shipping: boolean(),
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
meta_data: array(WCV3OrdersCouponLineMetaDataSchema),
|
||||||
|
nominal_amount: number()
|
||||||
|
});
|
||||||
|
const WCV3OrdersFeeLineMetaDataSchema = object({
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
key: string(),
|
||||||
|
value: unknown()
|
||||||
|
});
|
||||||
|
const WCV3OrdersFeeLineTaxSchema = object({
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
subtotal: string(),
|
||||||
|
total: string()
|
||||||
|
});
|
||||||
|
const WCV3OrdersFeeLineSchema = object({
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
meta_data: array(WCV3OrdersFeeLineMetaDataSchema),
|
||||||
|
name: string(),
|
||||||
|
tax_class: string(),
|
||||||
|
tax_status: enum_(TAX_STATUSES),
|
||||||
|
taxes: array(WCV3OrdersFeeLineTaxSchema),
|
||||||
|
total: string(),
|
||||||
|
total_tax: string()
|
||||||
|
});
|
||||||
|
const WCV3OrdersShippingLineMetaDataSchema = object({
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
key: string(),
|
||||||
|
value: unknown()
|
||||||
|
});
|
||||||
|
const WCV3OrdersShippingLineTaxSchema = object({
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
total: string()
|
||||||
|
});
|
||||||
|
const WCV3OrdersShippingLineSchema = object({
|
||||||
|
id: optional(pipe(number(), integer())),
|
||||||
|
meta_data: optional(array(WCV3OrdersShippingLineMetaDataSchema)),
|
||||||
|
method_id: optional(string()),
|
||||||
|
method_title: optional(string()),
|
||||||
|
taxes: optional(array(WCV3OrdersShippingLineTaxSchema)),
|
||||||
|
total: optional(string()),
|
||||||
|
total_tax: optional(string())
|
||||||
|
});
|
||||||
|
const WCV3OrdersLineItemImageSchema = object({
|
||||||
|
id: union([string(), pipe(number(), integer())]),
|
||||||
|
src: string()
|
||||||
|
});
|
||||||
|
const WCV3OrdersLineItemMetaDataSchema = object({
|
||||||
|
display_key: string(),
|
||||||
|
display_value: string(),
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
key: string(),
|
||||||
|
value: unknown()
|
||||||
|
});
|
||||||
|
const WCV3OrdersLineItemTaxSchema = object({
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
subtotal: string(),
|
||||||
|
total: string()
|
||||||
|
});
|
||||||
|
const WCV3OrdersLineItemSchema = object({
|
||||||
|
id: optional(pipe(number(), integer())),
|
||||||
|
image: optional(WCV3OrdersLineItemImageSchema),
|
||||||
|
meta_data: optional(array(WCV3OrdersLineItemMetaDataSchema)),
|
||||||
|
name: optional(string()),
|
||||||
|
parent_name: optional(union([string(), null_()])),
|
||||||
|
price: optional(number()),
|
||||||
|
product_id: optional(pipe(number(), integer())),
|
||||||
|
quantity: optional(pipe(number(), integer())),
|
||||||
|
sku: optional(string()),
|
||||||
|
subtotal: optional(string()),
|
||||||
|
subtotal_tax: optional(string()),
|
||||||
|
tax_class: optional(string()),
|
||||||
|
taxes: optional(array(WCV3OrdersLineItemTaxSchema)),
|
||||||
|
total: optional(string()),
|
||||||
|
total_tax: optional(string()),
|
||||||
|
variation_id: optional(pipe(number(), integer()))
|
||||||
|
});
|
||||||
|
const WCV3OrdersArgsSchema = object({
|
||||||
|
billing: optional(WCStoreBillingAddressSchema),
|
||||||
|
coupon_lines: optional(array(WCV3OrdersCouponLineSchema)),
|
||||||
|
currency: optional(string()),
|
||||||
|
customer_id: optional(pipe(number(), integer())),
|
||||||
|
customer_note: optional(string()),
|
||||||
|
fee_lines: optional(array(WCV3OrdersFeeLineSchema)),
|
||||||
|
line_items: optional(array(WCV3OrdersLineItemSchema)),
|
||||||
|
manual_update: optional(boolean()),
|
||||||
|
parent_id: optional(pipe(number(), integer())),
|
||||||
|
payment_method: optional(string()),
|
||||||
|
payment_method_title: optional(string()),
|
||||||
|
set_paid: optional(boolean()),
|
||||||
|
shipping: optional(WCStoreShippingAddressSchema),
|
||||||
|
shipping_lines: optional(array(WCV3OrdersShippingLineSchema)),
|
||||||
|
status: optional(enum_(ORDER_STATUSES)),
|
||||||
|
transaction_id: optional(string())
|
||||||
|
});
|
||||||
|
const WCV3OrderSchema = object({
|
||||||
|
billing: WCStoreBillingAddressSchema,
|
||||||
|
cart_hash: string(),
|
||||||
|
cart_tax: string(),
|
||||||
|
coupon_lines: array(WCV3OrdersCouponLineSchema),
|
||||||
|
created_via: string(),
|
||||||
|
currency: string(),
|
||||||
|
currency_symbol: string(),
|
||||||
|
customer_id: pipe(number(), integer()),
|
||||||
|
customer_ip_address: string(),
|
||||||
|
customer_note: string(),
|
||||||
|
customer_user_agent: string(),
|
||||||
|
date_completed: union([string(), null_()]),
|
||||||
|
date_completed_gmt: union([string(), null_()]),
|
||||||
|
// Date
|
||||||
|
date_created: string(),
|
||||||
|
date_created_gmt: string(),
|
||||||
|
date_modified: string(),
|
||||||
|
date_modified_gmt: string(),
|
||||||
|
date_paid: union([string(), null_()]),
|
||||||
|
date_paid_gmt: union([string(), null_()]),
|
||||||
|
discount_tax: string(),
|
||||||
|
discount_total: string(),
|
||||||
|
fee_lines: array(WCV3OrdersFeeLineSchema),
|
||||||
|
id: pipe(number(), integer()),
|
||||||
|
is_editable: boolean(),
|
||||||
|
line_items: array(WCV3OrdersLineItemSchema),
|
||||||
|
meta_data: unknown(),
|
||||||
|
needs_payment: boolean(),
|
||||||
|
needs_processing: boolean(),
|
||||||
|
number: string(),
|
||||||
|
order_key: string(),
|
||||||
|
parent_id: pipe(number(), integer()),
|
||||||
|
payment_method: string(),
|
||||||
|
payment_method_title: string(),
|
||||||
|
payment_url: string(),
|
||||||
|
prices_include_tax: boolean(),
|
||||||
|
refunds: array(unknown()),
|
||||||
|
shipping: WCStoreShippingAddressSchema,
|
||||||
|
shipping_lines: array(WCV3OrdersShippingLineSchema),
|
||||||
|
shipping_tax: string(),
|
||||||
|
shipping_total: string(),
|
||||||
|
status: enum_(ORDER_STATUSES),
|
||||||
|
tax_lines: array(unknown()),
|
||||||
|
total: string(),
|
||||||
|
total_tax: string(),
|
||||||
|
transaction_id: string(),
|
||||||
|
version: string()
|
||||||
|
});
|
||||||
|
export {
|
||||||
|
WCV3OrdersArgsSchema as W,
|
||||||
|
WCV3OrderSchema as a
|
||||||
|
};
|
||||||
//# sourceMappingURL=orders.js.map
|
//# sourceMappingURL=orders.js.map
|
||||||
|
|
|
||||||
|
|
@ -1,162 +1,20 @@
|
||||||
import { o as object, s as string, b as array, a as pipe, i as integer, n as number, e as enum_, u as unknown, g as union, c as optional, h as null_, d as boolean } from "./index.CXGAS3st.js";
|
const ORDER_STATUSES = {
|
||||||
import { T as TAX_STATUSES, O as ORDER_STATUSES } from "./orders3.js";
|
AUTO_DRAFT: "auto-draft",
|
||||||
import { W as WCStoreShippingAddressSchema, a as WCStoreBillingAddressSchema } from "./adresses.js";
|
CANCELLED: "cancelled",
|
||||||
const WCV3OrdersCouponLineMetaDataSchema = object({
|
CHECKOUT_DRAFT: "checkout-draft",
|
||||||
id: pipe(number(), integer()),
|
COMPLETED: "completed",
|
||||||
key: string(),
|
FAILED: "failed",
|
||||||
value: unknown()
|
ON_HOLD: "on-hold",
|
||||||
});
|
PENDING: "pending",
|
||||||
const WCV3OrdersCouponLineSchema = object({
|
PROCESSING: "processing",
|
||||||
code: string(),
|
REFUNDED: "refuneded"
|
||||||
discount: string(),
|
};
|
||||||
discount_tax: string(),
|
const TAX_STATUSES = {
|
||||||
discount_type: string(),
|
NONE: "none",
|
||||||
free_shipping: boolean(),
|
TAXABLE: "taxable"
|
||||||
id: pipe(number(), integer()),
|
};
|
||||||
meta_data: array(WCV3OrdersCouponLineMetaDataSchema),
|
|
||||||
nominal_amount: number()
|
|
||||||
});
|
|
||||||
const WCV3OrdersFeeLineMetaDataSchema = object({
|
|
||||||
id: pipe(number(), integer()),
|
|
||||||
key: string(),
|
|
||||||
value: unknown()
|
|
||||||
});
|
|
||||||
const WCV3OrdersFeeLineTaxSchema = object({
|
|
||||||
id: pipe(number(), integer()),
|
|
||||||
subtotal: string(),
|
|
||||||
total: string()
|
|
||||||
});
|
|
||||||
const WCV3OrdersFeeLineSchema = object({
|
|
||||||
id: pipe(number(), integer()),
|
|
||||||
meta_data: array(WCV3OrdersFeeLineMetaDataSchema),
|
|
||||||
name: string(),
|
|
||||||
tax_class: string(),
|
|
||||||
tax_status: enum_(TAX_STATUSES),
|
|
||||||
taxes: array(WCV3OrdersFeeLineTaxSchema),
|
|
||||||
total: string(),
|
|
||||||
total_tax: string()
|
|
||||||
});
|
|
||||||
const WCV3OrdersShippingLineMetaDataSchema = object({
|
|
||||||
id: pipe(number(), integer()),
|
|
||||||
key: string(),
|
|
||||||
value: unknown()
|
|
||||||
});
|
|
||||||
const WCV3OrdersShippingLineTaxSchema = object({
|
|
||||||
id: pipe(number(), integer()),
|
|
||||||
total: string()
|
|
||||||
});
|
|
||||||
const WCV3OrdersShippingLineSchema = object({
|
|
||||||
id: optional(pipe(number(), integer())),
|
|
||||||
meta_data: optional(array(WCV3OrdersShippingLineMetaDataSchema)),
|
|
||||||
method_id: optional(string()),
|
|
||||||
method_title: optional(string()),
|
|
||||||
taxes: optional(array(WCV3OrdersShippingLineTaxSchema)),
|
|
||||||
total: optional(string()),
|
|
||||||
total_tax: optional(string())
|
|
||||||
});
|
|
||||||
const WCV3OrdersLineItemImageSchema = object({
|
|
||||||
id: union([string(), pipe(number(), integer())]),
|
|
||||||
src: string()
|
|
||||||
});
|
|
||||||
const WCV3OrdersLineItemMetaDataSchema = object({
|
|
||||||
display_key: string(),
|
|
||||||
display_value: string(),
|
|
||||||
id: pipe(number(), integer()),
|
|
||||||
key: string(),
|
|
||||||
value: unknown()
|
|
||||||
});
|
|
||||||
const WCV3OrdersLineItemTaxSchema = object({
|
|
||||||
id: pipe(number(), integer()),
|
|
||||||
subtotal: string(),
|
|
||||||
total: string()
|
|
||||||
});
|
|
||||||
const WCV3OrdersLineItemSchema = object({
|
|
||||||
id: optional(pipe(number(), integer())),
|
|
||||||
image: optional(WCV3OrdersLineItemImageSchema),
|
|
||||||
meta_data: optional(array(WCV3OrdersLineItemMetaDataSchema)),
|
|
||||||
name: optional(string()),
|
|
||||||
parent_name: optional(union([string(), null_()])),
|
|
||||||
price: optional(number()),
|
|
||||||
product_id: optional(pipe(number(), integer())),
|
|
||||||
quantity: optional(pipe(number(), integer())),
|
|
||||||
sku: optional(string()),
|
|
||||||
subtotal: optional(string()),
|
|
||||||
subtotal_tax: optional(string()),
|
|
||||||
tax_class: optional(string()),
|
|
||||||
taxes: optional(array(WCV3OrdersLineItemTaxSchema)),
|
|
||||||
total: optional(string()),
|
|
||||||
total_tax: optional(string()),
|
|
||||||
variation_id: optional(pipe(number(), integer()))
|
|
||||||
});
|
|
||||||
const WCV3OrdersArgsSchema = object({
|
|
||||||
billing: optional(WCStoreBillingAddressSchema),
|
|
||||||
coupon_lines: optional(array(WCV3OrdersCouponLineSchema)),
|
|
||||||
currency: optional(string()),
|
|
||||||
customer_id: optional(pipe(number(), integer())),
|
|
||||||
customer_note: optional(string()),
|
|
||||||
fee_lines: optional(array(WCV3OrdersFeeLineSchema)),
|
|
||||||
line_items: optional(array(WCV3OrdersLineItemSchema)),
|
|
||||||
manual_update: optional(boolean()),
|
|
||||||
parent_id: optional(pipe(number(), integer())),
|
|
||||||
payment_method: optional(string()),
|
|
||||||
payment_method_title: optional(string()),
|
|
||||||
set_paid: optional(boolean()),
|
|
||||||
shipping: optional(WCStoreShippingAddressSchema),
|
|
||||||
shipping_lines: optional(array(WCV3OrdersShippingLineSchema)),
|
|
||||||
status: optional(enum_(ORDER_STATUSES)),
|
|
||||||
transaction_id: optional(string())
|
|
||||||
});
|
|
||||||
const WCV3OrderSchema = object({
|
|
||||||
billing: WCStoreBillingAddressSchema,
|
|
||||||
cart_hash: string(),
|
|
||||||
cart_tax: string(),
|
|
||||||
coupon_lines: array(WCV3OrdersCouponLineSchema),
|
|
||||||
created_via: string(),
|
|
||||||
currency: string(),
|
|
||||||
currency_symbol: string(),
|
|
||||||
customer_id: pipe(number(), integer()),
|
|
||||||
customer_ip_address: string(),
|
|
||||||
customer_note: string(),
|
|
||||||
customer_user_agent: string(),
|
|
||||||
date_completed: union([string(), null_()]),
|
|
||||||
date_completed_gmt: union([string(), null_()]),
|
|
||||||
// Date
|
|
||||||
date_created: string(),
|
|
||||||
date_created_gmt: string(),
|
|
||||||
date_modified: string(),
|
|
||||||
date_modified_gmt: string(),
|
|
||||||
date_paid: union([string(), null_()]),
|
|
||||||
date_paid_gmt: union([string(), null_()]),
|
|
||||||
discount_tax: string(),
|
|
||||||
discount_total: string(),
|
|
||||||
fee_lines: array(WCV3OrdersFeeLineSchema),
|
|
||||||
id: pipe(number(), integer()),
|
|
||||||
is_editable: boolean(),
|
|
||||||
line_items: array(WCV3OrdersLineItemSchema),
|
|
||||||
meta_data: unknown(),
|
|
||||||
needs_payment: boolean(),
|
|
||||||
needs_processing: boolean(),
|
|
||||||
number: string(),
|
|
||||||
order_key: string(),
|
|
||||||
parent_id: pipe(number(), integer()),
|
|
||||||
payment_method: string(),
|
|
||||||
payment_method_title: string(),
|
|
||||||
payment_url: string(),
|
|
||||||
prices_include_tax: boolean(),
|
|
||||||
refunds: array(unknown()),
|
|
||||||
shipping: WCStoreShippingAddressSchema,
|
|
||||||
shipping_lines: array(WCV3OrdersShippingLineSchema),
|
|
||||||
shipping_tax: string(),
|
|
||||||
shipping_total: string(),
|
|
||||||
status: enum_(ORDER_STATUSES),
|
|
||||||
tax_lines: array(unknown()),
|
|
||||||
total: string(),
|
|
||||||
total_tax: string(),
|
|
||||||
transaction_id: string(),
|
|
||||||
version: string()
|
|
||||||
});
|
|
||||||
export {
|
export {
|
||||||
WCV3OrdersArgsSchema as W,
|
ORDER_STATUSES as O,
|
||||||
WCV3OrderSchema as a
|
TAX_STATUSES as T
|
||||||
};
|
};
|
||||||
//# sourceMappingURL=orders2.js.map
|
//# sourceMappingURL=orders2.js.map
|
||||||
|
|
|
||||||
|
|
@ -1,20 +1,2 @@
|
||||||
const ORDER_STATUSES = {
|
|
||||||
AUTO_DRAFT: "auto-draft",
|
|
||||||
CANCELLED: "cancelled",
|
|
||||||
CHECKOUT_DRAFT: "checkout-draft",
|
|
||||||
COMPLETED: "completed",
|
|
||||||
FAILED: "failed",
|
|
||||||
ON_HOLD: "on-hold",
|
|
||||||
PENDING: "pending",
|
|
||||||
PROCESSING: "processing",
|
|
||||||
REFUNDED: "refuneded"
|
|
||||||
};
|
|
||||||
const TAX_STATUSES = {
|
|
||||||
NONE: "none",
|
|
||||||
TAXABLE: "taxable"
|
|
||||||
};
|
|
||||||
export {
|
|
||||||
ORDER_STATUSES as O,
|
|
||||||
TAX_STATUSES as T
|
|
||||||
};
|
|
||||||
//# sourceMappingURL=orders3.js.map
|
//# sourceMappingURL=orders3.js.map
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
{"version":3,"file":"orders3.js","sources":["../../src/scripts/constantes/orders.ts"],"sourcesContent":["export const ORDER_STATUSES = {\n AUTO_DRAFT: \"auto-draft\",\n CANCELLED: \"cancelled\",\n CHECKOUT_DRAFT: \"checkout-draft\",\n COMPLETED: \"completed\",\n FAILED: \"failed\",\n ON_HOLD: \"on-hold\",\n PENDING: \"pending\",\n PROCESSING: \"processing\",\n REFUNDED: \"refuneded\",\n} as const;\n\nexport const TAX_STATUSES = {\n NONE: \"none\",\n TAXABLE: \"taxable\",\n};\n"],"names":[],"mappings":"AAAO,MAAM,iBAAiB;AAAA,EAC5B,YAAY;AAAA,EACZ,WAAW;AAAA,EACX,gBAAgB;AAAA,EAChB,WAAW;AAAA,EACX,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,SAAS;AAAA,EACT,YAAY;AAAA,EACZ,UAAU;AACZ;AAEO,MAAM,eAAe;AAAA,EAC1B,MAAM;AAAA,EACN,SAAS;AACX;"}
|
{"version":3,"file":"orders3.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { o as object, c as optional, e as enum_, s as string, b as array, a as pipe, k as maxValue, m as minValue, n as number, i as integer, d as boolean, u as unknown, g as union, h as null_, f as url } from "./index.CXGAS3st.js";
|
import { o as object, c as optional, e as enum_, s as string, b as array, a as pipe, m as maxValue, k as minValue, n as number, i as integer, d as boolean, u as unknown, g as union, h as null_, f as url } from "./index.DeCaB8sW.js";
|
||||||
import { P as PRODUCT_TYPES, T as TAG_OPERATORS, S as STOCK_STATUSES, a as PRODUCT_STATUTES, R as RATINGS, O as ORDERBY_VALUES, b as ORDER_VALUES, D as DATE_COLUMN_VALUES, c as PRODUCTS_CONTEXTES, C as CATEGORY_OPERATORS, d as CATALOG_VISIBILITIES, A as ATTRIBUTES_RELATIONS, e as TAX_STATUTES, B as BACKORDERS_SETTINGS } from "./products2.js";
|
import { P as PRODUCT_TYPES, T as TAG_OPERATORS, S as STOCK_STATUSES, a as PRODUCT_STATUTES, R as RATINGS, O as ORDERBY_VALUES, b as ORDER_VALUES, D as DATE_COLUMN_VALUES, c as PRODUCTS_CONTEXTES, C as CATEGORY_OPERATORS, d as CATALOG_VISIBILITIES, A as ATTRIBUTES_RELATIONS, e as TAX_STATUTES, B as BACKORDERS_SETTINGS } from "./products2.js";
|
||||||
const WCV3ProductsArgsSchema = object({
|
const WCV3ProductsArgsSchema = object({
|
||||||
// Date ISO8601
|
// Date ISO8601
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { o as object, c as optional, e as enum_, s as string, b as array, a as pipe, k as maxValue, m as minValue, n as number, i as integer, d as boolean, u as unknown, g as union, h as null_ } from "./index.CXGAS3st.js";
|
import { o as object, c as optional, e as enum_, s as string, b as array, a as pipe, m as maxValue, k as minValue, n as number, i as integer, d as boolean, u as unknown, g as union, h as null_ } from "./index.DeCaB8sW.js";
|
||||||
import { P as PRODUCT_TYPES, T as TAG_OPERATORS, S as STOCK_STATUSES, R as RATINGS, O as ORDERBY_VALUES, b as ORDER_VALUES, D as DATE_COLUMN_VALUES, c as PRODUCTS_CONTEXTES, C as CATEGORY_OPERATORS, d as CATALOG_VISIBILITIES, A as ATTRIBUTES_RELATIONS } from "./products2.js";
|
import { P as PRODUCT_TYPES, T as TAG_OPERATORS, S as STOCK_STATUSES, R as RATINGS, O as ORDERBY_VALUES, b as ORDER_VALUES, D as DATE_COLUMN_VALUES, c as PRODUCTS_CONTEXTES, C as CATEGORY_OPERATORS, d as CATALOG_VISIBILITIES, A as ATTRIBUTES_RELATIONS } from "./products2.js";
|
||||||
object({
|
object({
|
||||||
// Date ISO8601
|
// Date ISO8601
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,11 @@
|
||||||
import { z, N } from "./index.CeK6pfoJ.js";
|
import { z, N } from "./index.CeK6pfoJ.js";
|
||||||
import { p as parse } from "./index.CXGAS3st.js";
|
import { p as parse } from "./index.DeCaB8sW.js";
|
||||||
import { E as ENTETE_WC_NONCE } from "./api.js";
|
import { E as ENTETE_WC_NONCE } from "./api.js";
|
||||||
import { b as leveBadRequestError, c as leveUnauthorizedError, d as leveNotFoundError, E as ErreurInconnue, a as leveErreur } from "./erreurs.js";
|
import { b as leveBadRequestError, c as leveUnauthorizedError, d as leveNotFoundError, E as ErreurInconnue, a as leveErreur } from "./erreurs.js";
|
||||||
import { e as estWCError } from "./erreurs2.js";
|
import { e as estWCError } from "./erreurs2.js";
|
||||||
import { p as pipe } from "./pipe.XPB0wEfw.js";
|
import { p as pipe } from "./pipe.XPB0wEfw.js";
|
||||||
import "./exports.DT-46nyp.js";
|
import "./exports.DT-46nyp.js";
|
||||||
const getBackend = (args) => fetch(
|
const getBackendAvecParametresUrl = (args) => fetch(
|
||||||
`${args.route}?${args.searchParams}`,
|
`${args.route}?${args.searchParams}`,
|
||||||
{
|
{
|
||||||
credentials: "same-origin",
|
credentials: "same-origin",
|
||||||
|
|
@ -40,7 +40,7 @@ const postBackend = (args) => fetch(
|
||||||
);
|
);
|
||||||
const traiteReponseBackendWCSelonCodesHTTP = (corpsReponse, schemaReponse) => z(corpsReponse).with({ body: N.select(), status: 400 }, estWCError, leveBadRequestError).with({ body: N.select(), status: 401 }, estWCError, leveUnauthorizedError).with({ body: N.select(), status: 404 }, estWCError, leveNotFoundError).with(N._, (corpsOkInconnu) => parse(schemaReponse, corpsOkInconnu)).otherwise((e) => pipe(e, ErreurInconnue, leveErreur));
|
const traiteReponseBackendWCSelonCodesHTTP = (corpsReponse, schemaReponse) => z(corpsReponse).with({ body: N.select(), status: 400 }, estWCError, leveBadRequestError).with({ body: N.select(), status: 401 }, estWCError, leveUnauthorizedError).with({ body: N.select(), status: 404 }, estWCError, leveNotFoundError).with(N._, (corpsOkInconnu) => parse(schemaReponse, corpsOkInconnu)).otherwise((e) => pipe(e, ErreurInconnue, leveErreur));
|
||||||
export {
|
export {
|
||||||
getBackend as g,
|
getBackendAvecParametresUrl as g,
|
||||||
postBackend as p,
|
postBackend as p,
|
||||||
traiteReponseBackendWCSelonCodesHTTP as t
|
traiteReponseBackendWCSelonCodesHTTP as t
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ import { p as pipe } from "./pipe.XPB0wEfw.js";
|
||||||
import "./erreurs.js";
|
import "./erreurs.js";
|
||||||
import "./exports.DT-46nyp.js";
|
import "./exports.DT-46nyp.js";
|
||||||
import "./Either.wHNxn7Os.js";
|
import "./Either.wHNxn7Os.js";
|
||||||
import "./index.CXGAS3st.js";
|
import "./index.DeCaB8sW.js";
|
||||||
import "./messages2.js";
|
import "./messages2.js";
|
||||||
import "./cart.js";
|
import "./cart.js";
|
||||||
import "./cart2.js";
|
import "./cart2.js";
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
var __defProp = Object.defineProperty;
|
var __defProp = Object.defineProperty;
|
||||||
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
||||||
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
||||||
import { T as SELECTEUR_BOUTON_MENU_MOBILE, U as SELECTEUR_MENU_MOBILE, V as ATTRIBUT_MENU_MOBILE_ACTIVE } from "./dom.js";
|
import { Z as SELECTEUR_BOUTON_MENU_MOBILE, _ as SELECTEUR_MENU_MOBILE, $ as ATTRIBUT_MENU_MOBILE_ACTIVE } from "./dom.js";
|
||||||
import { a as recupereElementDansDocumentOuLeve } from "./utils.js";
|
import { a as recupereElementDansDocumentOuLeve } from "./utils.js";
|
||||||
import "./dom2.js";
|
import "./dom2.js";
|
||||||
import "./erreurs.js";
|
import "./erreurs.js";
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { W as SELECTEUR_CONTENEUR_STORYTELLING_A_PROPOS, X as SELECTEUR_EPINGLE, Y as SELECTEUR_BOITE_TEXTE, Z as ATTRIBUT_ID_ENSEMBLE_EPINGLE_BOITE, _ as ATTRIBUT_ENSEMBLE_EPINGLE_BOITE_ACTIF, $ as CLASS_BOUTON_FERMETURE_BOITE_TEXTE, a0 as CLASS_EPINGLE } from "./dom.js";
|
import { a0 as SELECTEUR_CONTENEUR_STORYTELLING_A_PROPOS, a1 as SELECTEUR_EPINGLE, a2 as SELECTEUR_BOITE_TEXTE, a3 as ATTRIBUT_ID_ENSEMBLE_EPINGLE_BOITE, a4 as ATTRIBUT_ENSEMBLE_EPINGLE_BOITE_ACTIF, a5 as CLASS_BOUTON_FERMETURE_BOITE_TEXTE, a6 as CLASS_EPINGLE } from "./dom.js";
|
||||||
import { a as recupereElementDansDocumentOuLeve, b as recupereElementsDansDocumentOuLeve } from "./utils.js";
|
import { a as recupereElementDansDocumentOuLeve, b as recupereElementsDansDocumentOuLeve } from "./utils.js";
|
||||||
import { k as reduceU, q as concat, v as valFromOption, s as some, i as equal, t as nullable_to_opt, R as Ra } from "./dom2.js";
|
import { k as reduceU, q as concat, v as valFromOption, s as some, i as equal, t as nullable_to_opt, R as Ra } from "./dom2.js";
|
||||||
import { p as pipe } from "./pipe.XPB0wEfw.js";
|
import { p as pipe } from "./pipe.XPB0wEfw.js";
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,11 @@
|
||||||
import { z, N } from "./index.CeK6pfoJ.js";
|
import { z, N } from "./index.CeK6pfoJ.js";
|
||||||
import { p as parse } from "./index.CXGAS3st.js";
|
import { p as parse } from "./index.DeCaB8sW.js";
|
||||||
import { R as ROUTE_API_NOUVELLE_PRODUCTS } from "./api.js";
|
import { R as ROUTE_API_NOUVELLE_PRODUCTS } from "./api.js";
|
||||||
import { g as SELECTEUR_GRILLE_PRODUITS, h as SELECTEUR_BOUTON_PLUS_PRODUITS, i as ATTRIBUT_ID_CATEGORIE_PRODUITS, j as ATTRIBUT_PAGE, k as ATTRIBUT_HIDDEN } from "./dom.js";
|
import { g as SELECTEUR_GRILLE_PRODUITS, h as SELECTEUR_BOUTON_PLUS_PRODUITS, i as ATTRIBUT_ID_CATEGORIE_PRODUITS, j as ATTRIBUT_PAGE, k as ATTRIBUT_HIDDEN } from "./dom.js";
|
||||||
import { h as html } from "./dom2.js";
|
import { h as html } from "./dom2.js";
|
||||||
import { l as leveServerError } from "./erreurs.js";
|
import { l as leveServerError } from "./erreurs.js";
|
||||||
import { e as estReponse500 } from "./gardes.js";
|
import { e as estReponse500 } from "./gardes.js";
|
||||||
import { g as getBackend, t as traiteReponseBackendWCSelonCodesHTTP } from "./reseau.js";
|
import { g as getBackendAvecParametresUrl, t as traiteReponseBackendWCSelonCodesHTTP } from "./reseau.js";
|
||||||
import { W as WCV3ProductsArgsSchema, a as WCV3ProductsSchema } from "./products.js";
|
import { W as WCV3ProductsArgsSchema, a as WCV3ProductsSchema } from "./products.js";
|
||||||
import { a as recupereElementDansDocumentOuLeve, r as recupereElementDocumentEither } from "./utils.js";
|
import { a as recupereElementDansDocumentOuLeve, r as recupereElementDocumentEither } from "./utils.js";
|
||||||
import { E as EitherAsync } from "./MaybeAsync.Ba-OfjWy.js";
|
import { E as EitherAsync } from "./MaybeAsync.Ba-OfjWy.js";
|
||||||
|
|
@ -35,7 +35,7 @@ const initialisePageBoutique = () => {
|
||||||
Either.encase(() => parse(WCV3ProductsArgsSchema, args)).map(
|
Either.encase(() => parse(WCV3ProductsArgsSchema, args)).map(
|
||||||
async (args2) => {
|
async (args2) => {
|
||||||
await EitherAsync(
|
await EitherAsync(
|
||||||
() => getBackend({
|
() => getBackendAvecParametresUrl({
|
||||||
authString: ETATS_PAGE.authString,
|
authString: ETATS_PAGE.authString,
|
||||||
nonce: ETATS_PAGE.nonce,
|
nonce: ETATS_PAGE.nonce,
|
||||||
route: ROUTE_API_NOUVELLE_PRODUCTS,
|
route: ROUTE_API_NOUVELLE_PRODUCTS,
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,15 @@
|
||||||
|
import { l as SELECTEUR_BOUTON_CODE_PROMO, m as SELECTEUR_CHAMP_CODE_PROMO, n as SELECTEUR_ENSEMBLE_CODE_PROMO, o as SELECTEUR_TOTAL_REDUCTION_VALEUR, p as SELECTEUR_TOTAL_REDUCTION } from "./dom.js";
|
||||||
|
import { a as recupereElementDansDocumentOuLeve } from "./utils.js";
|
||||||
|
import "./dom2.js";
|
||||||
|
import "./erreurs.js";
|
||||||
|
import "./exports.DT-46nyp.js";
|
||||||
|
import "./Either.wHNxn7Os.js";
|
||||||
|
import "./pipe.XPB0wEfw.js";
|
||||||
|
({
|
||||||
|
TOTAL_REDUCTION_LIGNE: recupereElementDansDocumentOuLeve(SELECTEUR_TOTAL_REDUCTION),
|
||||||
|
TOTAL_REDUCTION_VALEUR: recupereElementDansDocumentOuLeve(SELECTEUR_TOTAL_REDUCTION_VALEUR),
|
||||||
|
ENSEMBLE_CODE_PROMO: recupereElementDansDocumentOuLeve(SELECTEUR_ENSEMBLE_CODE_PROMO),
|
||||||
|
CHAMP_CODE_PROMO: recupereElementDansDocumentOuLeve(SELECTEUR_CHAMP_CODE_PROMO),
|
||||||
|
BOUTON_CODE_PROMO: recupereElementDansDocumentOuLeve(SELECTEUR_BOUTON_CODE_PROMO)
|
||||||
|
});
|
||||||
|
//# sourceMappingURL=scripts-page-panier-code-promo.js.map
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
{"version":3,"file":"scripts-page-panier-code-promo.js","sources":["../../src/scripts/scripts-page-panier-code-promo.ts"],"sourcesContent":["/**\n * Scripts pour la gestion des codes promos (coupons) sur la Page Panier.\n */\n\nimport { Maybe } from \"purify-ts\";\nimport { match, P } from \"ts-pattern\";\nimport {\n ATTRIBUT_CODE_PROMO_PRESENT,\n SELECTEUR_BOUTON_CODE_PROMO,\n SELECTEUR_CHAMP_CODE_PROMO,\n SELECTEUR_ENSEMBLE_CODE_PROMO,\n SELECTEUR_TOTAL_REDUCTION,\n SELECTEUR_TOTAL_REDUCTION_VALEUR,\n} from \"./constantes/dom\";\nimport { correspondCibleSelecteur } from \"./lib/dom\";\nimport { recupereElementDansDocumentOuLeve } from \"./lib/utils\";\n\n/** États utiles pour les scripts de la page. */\ntype EtatsPage = {\n authString: string;\n /** Un nonce pour l'authentification de requêtes API vers le backend WooCommerce. */\n nonce: string;\n};\n\n// @ts-expect-error -- États injectés par le modèle PHP\n// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment -- États injectés par le modèle PHP\nconst ETATS_PAGE: EtatsPage = _etats;\n\nconst ELEMENTS = {\n TOTAL_REDUCTION_LIGNE: recupereElementDansDocumentOuLeve<HTMLDivElement>(SELECTEUR_TOTAL_REDUCTION),\n TOTAL_REDUCTION_VALEUR: recupereElementDansDocumentOuLeve<HTMLSpanElement>(SELECTEUR_TOTAL_REDUCTION_VALEUR),\n ENSEMBLE_CODE_PROMO: recupereElementDansDocumentOuLeve<HTMLDivElement>(SELECTEUR_ENSEMBLE_CODE_PROMO),\n CHAMP_CODE_PROMO: recupereElementDansDocumentOuLeve<HTMLInputElement>(SELECTEUR_CHAMP_CODE_PROMO),\n BOUTON_CODE_PROMO: recupereElementDansDocumentOuLeve<HTMLButtonElement>(SELECTEUR_BOUTON_CODE_PROMO),\n};\n\nconst initialiseElementsCodePromo = (): void => {\n // Récupère la présence s'il existe\n const recupereCodePromo = (): null | string =>\n Maybe\n .fromFalsy(ELEMENTS.ENSEMBLE_CODE_PROMO.hasAttribute(ATTRIBUT_CODE_PROMO_PRESENT))\n .chain(() => Maybe.fromNullable(ELEMENTS.CHAMP_CODE_PROMO.value))\n .extractNullable();\n\n // Créé la délégation d'Événements\n ELEMENTS.ENSEMBLE_CODE_PROMO.addEventListener(\"click\", (evenement: Event) => {\n match({\n codePromo: recupereCodePromo(),\n cible: evenement.target,\n })\n .with(\n {\n codePromo: P.string,\n cible: P.when(cible => correspondCibleSelecteur<HTMLButtonElement>(cible, SELECTEUR_BOUTON_CODE_PROMO)),\n },\n v => {\n console.debug(v);\n },\n )\n // Ne rien faire en cas de code promo absent\n .with(\n {\n codePromo: P.nullish,\n cible: P.when(cible => correspondCibleSelecteur<HTMLButtonElement>(cible, SELECTEUR_BOUTON_CODE_PROMO)),\n },\n v => {\n console.debug(v);\n },\n );\n });\n};\n"],"names":[],"mappings":";;;;;;;CA4BiB;AAAA,EACf,uBAAuB,kCAAkD,yBAAyB;AAAA,EAClG,wBAAwB,kCAAmD,gCAAgC;AAAA,EAC3G,qBAAqB,kCAAkD,6BAA6B;AAAA,EACpG,kBAAkB,kCAAoD,0BAA0B;AAAA,EAChG,mBAAmB,kCAAqD,2BAA2B;AACrG;"}
|
||||||
|
|
@ -1,30 +1,33 @@
|
||||||
import { z } from "./index.CeK6pfoJ.js";
|
import { z, N } from "./index.CeK6pfoJ.js";
|
||||||
import { p as parse, V as ValiError } from "./index.CXGAS3st.js";
|
import { p as parse, V as ValiError } from "./index.DeCaB8sW.js";
|
||||||
import { a as ROUTE_API_RETIRE_ARTICLE_PANIER, b as ROUTE_API_MAJ_ARTICLE_PANIER, c as ROUTE_API_MAJ_CLIENT, d as ROUTE_API_NOUVELLE_COMMANDES } from "./api.js";
|
import { a as ROUTE_API_RETIRE_ARTICLE_PANIER, b as ROUTE_API_MAJ_ARTICLE_PANIER, c as ROUTE_API_MAJ_CLIENT, d as ROUTE_API_NOUVELLE_COMMANDES, e as ROUTE_API_RETIRE_COUPON, f as ROUTE_API_APPLIQUE_COUPON } from "./api.js";
|
||||||
import { l as SELECTEUR_ENTREES_PANIER, m as SELECTEUR_CONTENEUR_PANIER, n as SELECTEUR_SOUS_TOTAL_PRODUITS, o as SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT, p as SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE, q as SELECTEUR_INSTRUCTIONS_CLIENT, r as SELECTEUR_TOTAL_PANIER, s as SELECTEUR_BOUTON_SEPARATION_ADRESSES, t as SELECTEUR_FORMULAIRE_PANIER, u as SELECTEUR_FORMULAIRE_FACTURATION, v as SELECTEUR_BOUTON_ACTIONS_FORMULAIRE, w as ATTRIBUT_CLE_PANIER, x as SELECTEUR_BOUTON_SOUSTRACTION_QUANTITE, y as SELECTEUR_CHAMP_QUANTITE_LIGNE_PANIER, z as SELECTEUR_BOUTON_ADDITION_QUANTITE, B as SELECTEUR_BOUTON_SUPPRESSION_PANIER, C as ATTRIBUT_DESACTIVE, A as ATTRIBUT_CONTIENT_ARTICLES, D as SELECTEUR_PRIX_LIGNE_PANIER, k as ATTRIBUT_HIDDEN } from "./dom.js";
|
import { q as SELECTEUR_ENTREES_PANIER, r as SELECTEUR_CONTENEUR_PANIER, s as SELECTEUR_SOUS_TOTAL_PRODUITS, t as SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT, u as SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE, p as SELECTEUR_TOTAL_REDUCTION, o as SELECTEUR_TOTAL_REDUCTION_VALEUR, v as SELECTEUR_INSTRUCTIONS_CLIENT, w as SELECTEUR_TOTAL_PANIER, x as SELECTEUR_BOUTON_SEPARATION_ADRESSES, n as SELECTEUR_ENSEMBLE_CODE_PROMO, m as SELECTEUR_CHAMP_CODE_PROMO, l as SELECTEUR_BOUTON_CODE_PROMO, y as SELECTEUR_FORMULAIRE_PANIER, z as SELECTEUR_FORMULAIRE_FACTURATION, B as SELECTEUR_BOUTON_ACTIONS_FORMULAIRE, C as ATTRIBUT_CLE_PANIER, D as SELECTEUR_BOUTON_SOUSTRACTION_QUANTITE, E as SELECTEUR_CHAMP_QUANTITE_LIGNE_PANIER, F as SELECTEUR_BOUTON_ADDITION_QUANTITE, G as SELECTEUR_BOUTON_SUPPRESSION_PANIER, H as ATTRIBUT_DESACTIVE, A as ATTRIBUT_CONTIENT_ARTICLES, I as SELECTEUR_PRIX_LIGNE_PANIER, k as ATTRIBUT_HIDDEN, J as ATTRIBUT_CODE_PROMO_PRESENT } from "./dom.js";
|
||||||
import { N as NOM_CANAL_BOUTON_PANIER, a as NOM_CANAL_CONTENU_PANIER } from "./messages3.js";
|
import { N as NOM_CANAL_BOUTON_PANIER, a as NOM_CANAL_CONTENU_PANIER } from "./messages3.js";
|
||||||
import { r as recupereElementOuLeve, a as recupereElementAvecSelecteur, b as recupereElementsAvecSelecteur, e as eitherSessionStorageGet, c as eitherJsonParse } from "./dom2.js";
|
import { r as recupereElementOuLeve, a as recupereElementAvecSelecteur, b as recupereElementsAvecSelecteur, e as eitherSessionStorageGet, c as eitherJsonParse } from "./dom2.js";
|
||||||
import { l as leveServerError, r as reporteErreur, a as leveErreur } from "./erreurs.js";
|
import { l as leveServerError, r as reporteErreur, a as leveErreur, S as ServerError } from "./erreurs.js";
|
||||||
import { e as estReponse500, a as estError } from "./gardes.js";
|
import { e as estReponse500, a as estError } from "./gardes.js";
|
||||||
import { e as emetMessageMajBoutonPanier, a as emetMessageMajContenuPanier, v as valideMessageMajBoutonPanier, b as valideMessageMajContenuPanier } from "./messages.js";
|
import { e as emetMessageMajBoutonPanier, a as emetMessageMajContenuPanier, v as valideMessageMajBoutonPanier, b as valideMessageMajContenuPanier } from "./messages.js";
|
||||||
import { p as postBackend, t as traiteReponseBackendWCSelonCodesHTTP } from "./reseau.js";
|
import { p as postBackend, t as traiteReponseBackendWCSelonCodesHTTP } from "./reseau.js";
|
||||||
|
import { W as WCStoreCartApplyCouponArgsSchema } from "./cart-apply-coupon.js";
|
||||||
|
import { W as WCStoreCartRemoveCouponArgsSchema } from "./cart-remove-coupon.js";
|
||||||
import { W as WCStoreCartRemoveItemArgsSchema } from "./cart-remove-item.js";
|
import { W as WCStoreCartRemoveItemArgsSchema } from "./cart-remove-item.js";
|
||||||
import { W as WCStoreCartUpdateCustomerArgsSchema } from "./cart-update-customer.js";
|
import { W as WCStoreCartUpdateCustomerArgsSchema } from "./cart-update-customer.js";
|
||||||
import { W as WCStoreCartUpdateItemArgsSchema } from "./cart-update-item.js";
|
import { W as WCStoreCartUpdateItemArgsSchema } from "./cart-update-item.js";
|
||||||
import { W as WCStoreCartSchema } from "./cart.js";
|
import { W as WCStoreCartSchema } from "./cart.js";
|
||||||
import { W as WCStoreShippingRateShippingRateSchema } from "./couts-livraison.js";
|
import { W as WCStoreShippingRateShippingRateSchema } from "./couts-livraison.js";
|
||||||
import { W as WCV3OrdersArgsSchema, a as WCV3OrderSchema } from "./orders2.js";
|
import { W as WCV3OrdersArgsSchema, a as WCV3OrderSchema } from "./orders.js";
|
||||||
import { c as recupereElementsDocumentEither, r as recupereElementDocumentEither, a as recupereElementDansDocumentOuLeve, y, p as propEither } from "./utils.js";
|
import { c as recupereElementsDocumentEither, r as recupereElementDocumentEither, a as recupereElementDansDocumentOuLeve, y, p as propEither } from "./utils.js";
|
||||||
import { e as eitherParse } from "./validation.js";
|
import { e as eitherParse } from "./validation.js";
|
||||||
import { p as pipe } from "./pipe.XPB0wEfw.js";
|
import { p as pipe } from "./pipe.XPB0wEfw.js";
|
||||||
import { l } from "./index-0eef19ec.CFsloYN6.js";
|
import { l } from "./index-0eef19ec.CFsloYN6.js";
|
||||||
|
import { E as EitherAsync } from "./MaybeAsync.Ba-OfjWy.js";
|
||||||
import { M as Maybe, E as Either } from "./Either.wHNxn7Os.js";
|
import { M as Maybe, E as Either } from "./Either.wHNxn7Os.js";
|
||||||
import "./exports.DT-46nyp.js";
|
import "./exports.DT-46nyp.js";
|
||||||
import "./messages2.js";
|
import "./messages2.js";
|
||||||
import "./erreurs2.js";
|
import "./erreurs2.js";
|
||||||
import "./adresses.js";
|
import "./adresses.js";
|
||||||
import "./cart2.js";
|
import "./cart2.js";
|
||||||
import "./orders3.js";
|
import "./orders2.js";
|
||||||
import "./belt_Option-91f3b350.BKMoZFhU.js";
|
import "./belt_Option-91f3b350.BKMoZFhU.js";
|
||||||
const ETATS_PAGE = _etats;
|
const ETATS_PAGE = _etats;
|
||||||
const ENTREES_PANIER_EITHER = recupereElementsDocumentEither(
|
const ENTREES_PANIER_EITHER = recupereElementsDocumentEither(
|
||||||
|
|
@ -46,6 +49,10 @@ const SOUS_TOTAL_LIVRAISON_PRESTATAIRE = pipe(
|
||||||
recupereElementDocumentEither(SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE),
|
recupereElementDocumentEither(SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE),
|
||||||
recupereElementOuLeve
|
recupereElementOuLeve
|
||||||
);
|
);
|
||||||
|
const SOUS_TOTAL_REDUCTION_LIGNE = recupereElementDansDocumentOuLeve(SELECTEUR_TOTAL_REDUCTION);
|
||||||
|
const SOUS_TOTAL_REDUCTION_VALEUR = recupereElementDansDocumentOuLeve(
|
||||||
|
SELECTEUR_TOTAL_REDUCTION_VALEUR
|
||||||
|
);
|
||||||
const INSTRUCTIONS_CLIENT = recupereElementDansDocumentOuLeve(
|
const INSTRUCTIONS_CLIENT = recupereElementDansDocumentOuLeve(
|
||||||
SELECTEUR_INSTRUCTIONS_CLIENT
|
SELECTEUR_INSTRUCTIONS_CLIENT
|
||||||
);
|
);
|
||||||
|
|
@ -57,6 +64,15 @@ const BOUTON_SEPARATION_ADRESSES = pipe(
|
||||||
recupereElementDocumentEither(SELECTEUR_BOUTON_SEPARATION_ADRESSES),
|
recupereElementDocumentEither(SELECTEUR_BOUTON_SEPARATION_ADRESSES),
|
||||||
recupereElementOuLeve
|
recupereElementOuLeve
|
||||||
);
|
);
|
||||||
|
const ENSEMBLE_CODE_PROMO = recupereElementDansDocumentOuLeve(
|
||||||
|
SELECTEUR_ENSEMBLE_CODE_PROMO
|
||||||
|
);
|
||||||
|
const CHAMP_CODE_PROMO = recupereElementDansDocumentOuLeve(
|
||||||
|
SELECTEUR_CHAMP_CODE_PROMO
|
||||||
|
);
|
||||||
|
let BOUTON_CODE_PROMO = recupereElementDansDocumentOuLeve(
|
||||||
|
SELECTEUR_BOUTON_CODE_PROMO
|
||||||
|
);
|
||||||
const FORMULAIRE_PANIER = pipe(
|
const FORMULAIRE_PANIER = pipe(
|
||||||
recupereElementDocumentEither(SELECTEUR_FORMULAIRE_PANIER),
|
recupereElementDocumentEither(SELECTEUR_FORMULAIRE_PANIER),
|
||||||
recupereElementOuLeve
|
recupereElementOuLeve
|
||||||
|
|
@ -147,7 +163,7 @@ const initialiseMajEntreesPanier = () => {
|
||||||
});
|
});
|
||||||
}).ifLeft((erreur) => reporteErreur(erreur));
|
}).ifLeft((erreur) => reporteErreur(erreur));
|
||||||
});
|
});
|
||||||
boutonSoustraction.addEventListener("click", (evenement) => {
|
boutonSoustraction.addEventListener("click", () => {
|
||||||
Maybe.fromNullable(champQuantite.valueAsNumber).filter((valeur) => valeur > 1).ifJust((valeur) => {
|
Maybe.fromNullable(champQuantite.valueAsNumber).filter((valeur) => valeur > 1).ifJust((valeur) => {
|
||||||
Either.encase(
|
Either.encase(
|
||||||
() => parse(WCStoreCartUpdateItemArgsSchema, { key: clePanier, quantity: valeur - 1 })
|
() => parse(WCStoreCartUpdateItemArgsSchema, { key: clePanier, quantity: valeur - 1 })
|
||||||
|
|
@ -250,7 +266,7 @@ const initialiseMajContenuPanier = () => {
|
||||||
SELECTEUR_CHAMP_QUANTITE_LIGNE_PANIER
|
SELECTEUR_CHAMP_QUANTITE_LIGNE_PANIER
|
||||||
);
|
);
|
||||||
entree.setAttribute("data-quantite", String(ligne.quantity));
|
entree.setAttribute("data-quantite", String(ligne.quantity));
|
||||||
prixLigne.textContent = `${String(Number(ligne.totals.line_total) / 100)}€`;
|
prixLigne.textContent = `${String(Number(ligne.totals.line_subtotal) / 100)}€`;
|
||||||
champQuantite.setAttribute("value", String(ligne.quantity));
|
champQuantite.setAttribute("value", String(ligne.quantity));
|
||||||
majEtatsActivationBoutons(entrees);
|
majEtatsActivationBoutons(entrees);
|
||||||
}
|
}
|
||||||
|
|
@ -359,6 +375,81 @@ const initialiseBoutonActions = () => {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
const initialiseElementsCodePromo = () => {
|
||||||
|
const codePromoPresent = ENSEMBLE_CODE_PROMO.hasAttribute(ATTRIBUT_CODE_PROMO_PRESENT);
|
||||||
|
BOUTON_CODE_PROMO.outerHTML = BOUTON_CODE_PROMO.outerHTML;
|
||||||
|
BOUTON_CODE_PROMO = recupereElementDansDocumentOuLeve(SELECTEUR_BOUTON_CODE_PROMO);
|
||||||
|
if (codePromoPresent) {
|
||||||
|
BOUTON_CODE_PROMO.addEventListener("click", () => {
|
||||||
|
const code = CHAMP_CODE_PROMO.value;
|
||||||
|
EitherAsync.liftEither(eitherParse({ code }, WCStoreCartRemoveCouponArgsSchema)).map(
|
||||||
|
(args) => postBackend({
|
||||||
|
corps: JSON.stringify(args),
|
||||||
|
nonce: ETATS_PAGE.nonce,
|
||||||
|
route: ROUTE_API_RETIRE_COUPON
|
||||||
|
})
|
||||||
|
).chain(
|
||||||
|
async (reponse) => EitherAsync(async ({ throwE }) => {
|
||||||
|
if (estReponse500(reponse)) throwE(new ServerError("500 Server Error"));
|
||||||
|
return await reponse.json();
|
||||||
|
})
|
||||||
|
).chain(
|
||||||
|
(corpsReponse) => EitherAsync(
|
||||||
|
({ liftEither }) => liftEither(eitherParse(corpsReponse, WCStoreCartSchema))
|
||||||
|
)
|
||||||
|
).ifRight((panier) => {
|
||||||
|
const totalPanier = `${String(Number(panier.totals.total_price) / 100)}€`;
|
||||||
|
ENSEMBLE_CODE_PROMO.removeAttribute(ATTRIBUT_CODE_PROMO_PRESENT);
|
||||||
|
BOUTON_CODE_PROMO.textContent = "Apply";
|
||||||
|
CHAMP_CODE_PROMO.value = "";
|
||||||
|
CHAMP_CODE_PROMO.toggleAttribute(ATTRIBUT_DESACTIVE);
|
||||||
|
TOTAL_PANIER.textContent = totalPanier;
|
||||||
|
SOUS_TOTAL_REDUCTION_VALEUR.textContent = "-0€";
|
||||||
|
SOUS_TOTAL_REDUCTION_LIGNE.setAttribute(ATTRIBUT_HIDDEN, "");
|
||||||
|
initialiseElementsCodePromo();
|
||||||
|
}).ifLeft((e) => {
|
||||||
|
console.error("requête", e);
|
||||||
|
if (e instanceof ValiError) console.error(e.issues);
|
||||||
|
}).run();
|
||||||
|
});
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
BOUTON_CODE_PROMO.addEventListener("click", () => {
|
||||||
|
const codePromo = Maybe.fromFalsy(CHAMP_CODE_PROMO.value.trim()).toEither(new TypeError("Aucun code promo n'a été renseigné.")).chain((code) => eitherParse({ code }, WCStoreCartApplyCouponArgsSchema)).ifRight((args) => console.debug(args)).ifLeft(
|
||||||
|
(erreur) => z(erreur).with(N.instanceOf(ValiError), (e) => console.error("codePromo", e.issues)).with(N.instanceOf(TypeError), (e) => console.error("codePromo", e)).exhaustive()
|
||||||
|
);
|
||||||
|
EitherAsync.liftEither(codePromo).map(
|
||||||
|
async (args) => await postBackend({
|
||||||
|
corps: JSON.stringify(args),
|
||||||
|
nonce: ETATS_PAGE.nonce,
|
||||||
|
route: ROUTE_API_APPLIQUE_COUPON
|
||||||
|
})
|
||||||
|
).chain(
|
||||||
|
async (reponse) => EitherAsync(async ({ throwE }) => {
|
||||||
|
if (estReponse500(reponse)) throwE(new ServerError("500 Server Error"));
|
||||||
|
return await reponse.json();
|
||||||
|
})
|
||||||
|
).chain(
|
||||||
|
(corpsReponse) => EitherAsync(
|
||||||
|
({ liftEither }) => liftEither(eitherParse(corpsReponse, WCStoreCartSchema))
|
||||||
|
)
|
||||||
|
).ifRight((panier) => {
|
||||||
|
const totalReduction = `-${String(Number(panier.totals.total_discount) / 100)}€`;
|
||||||
|
const totalPanier = `${Number(panier.totals.total_price) / 100}€`;
|
||||||
|
ENSEMBLE_CODE_PROMO.setAttribute(ATTRIBUT_CODE_PROMO_PRESENT, "");
|
||||||
|
BOUTON_CODE_PROMO.textContent = "Remove";
|
||||||
|
CHAMP_CODE_PROMO.value = panier.coupons[0].code;
|
||||||
|
CHAMP_CODE_PROMO.toggleAttribute(ATTRIBUT_DESACTIVE);
|
||||||
|
TOTAL_PANIER.textContent = totalPanier;
|
||||||
|
SOUS_TOTAL_REDUCTION_VALEUR.textContent = totalReduction;
|
||||||
|
SOUS_TOTAL_REDUCTION_LIGNE.removeAttribute(ATTRIBUT_HIDDEN);
|
||||||
|
initialiseElementsCodePromo();
|
||||||
|
}).ifLeft((e) => {
|
||||||
|
console.error("requête", e);
|
||||||
|
if (e instanceof ValiError) console.error(e.issues);
|
||||||
|
}).run();
|
||||||
|
});
|
||||||
|
};
|
||||||
const initialiseBoutonCreationCommande = () => {
|
const initialiseBoutonCreationCommande = () => {
|
||||||
BOUTON_ACTIONS_FORMULAIRE.outerHTML = BOUTON_ACTIONS_FORMULAIRE.outerHTML;
|
BOUTON_ACTIONS_FORMULAIRE.outerHTML = BOUTON_ACTIONS_FORMULAIRE.outerHTML;
|
||||||
BOUTON_ACTIONS_FORMULAIRE = recupereElementDansDocumentOuLeve(SELECTEUR_BOUTON_ACTIONS_FORMULAIRE);
|
BOUTON_ACTIONS_FORMULAIRE = recupereElementDansDocumentOuLeve(SELECTEUR_BOUTON_ACTIONS_FORMULAIRE);
|
||||||
|
|
@ -452,5 +543,6 @@ document.addEventListener("DOMContentLoaded", () => {
|
||||||
initialiseMajContenuPanier();
|
initialiseMajContenuPanier();
|
||||||
initialiseMajFormulairesPanier();
|
initialiseMajFormulairesPanier();
|
||||||
initialiseBoutonActions();
|
initialiseBoutonActions();
|
||||||
|
initialiseElementsCodePromo();
|
||||||
});
|
});
|
||||||
//# sourceMappingURL=scripts-page-panier.js.map
|
//# sourceMappingURL=scripts-page-panier.js.map
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { z } from "./index.CeK6pfoJ.js";
|
import { z } from "./index.CeK6pfoJ.js";
|
||||||
import { e as ROUTE_API_AJOUTE_ARTICLE_PANIER, E as ENTETE_WC_NONCE } from "./api.js";
|
import { g as ROUTE_API_AJOUTE_ARTICLE_PANIER, E as ENTETE_WC_NONCE } from "./api.js";
|
||||||
import { E as SELECTEUR_BOUTON_AJOUT_PANIER, F as SELECTEUR_SELECTEUR_QUANTITE, G as SELECTEUR_PRIX_PRODUIT, H as SELECTEUR_LIENS_ONGLETS, I as SELECTEUR_SECTIONS_CONTENUS, J as ATTRIBUT_ARIA_SELECTED, k as ATTRIBUT_HIDDEN, C as ATTRIBUT_DESACTIVE, K as ATTRIBUT_PRIX, L as SELECTEUR_CONTENEUR_FLECHES_DEFILEMENT, M as SELECTEUR_FLECHE_DEFILEMENT_GAUCHE, N as SELECTEUR_FLECHE_DEFILEMENT_DROITE, O as SELECTEUR_PHOTOS_PRODUIT, P as SELECTEUR_IMAGE_COLONNE_GAUCHE, Q as SELECTEUR_IMAGES_COLONNE_DROITE, R as ATTRIBUT_INDEX_IMAGE_ACTIVE } from "./dom.js";
|
import { K as SELECTEUR_BOUTON_AJOUT_PANIER, L as SELECTEUR_SELECTEUR_QUANTITE, M as SELECTEUR_PRIX_PRODUIT, N as SELECTEUR_LIENS_ONGLETS, O as SELECTEUR_SECTIONS_CONTENUS, P as ATTRIBUT_ARIA_SELECTED, k as ATTRIBUT_HIDDEN, H as ATTRIBUT_DESACTIVE, Q as ATTRIBUT_PRIX, R as SELECTEUR_CONTENEUR_FLECHES_DEFILEMENT, T as SELECTEUR_FLECHE_DEFILEMENT_GAUCHE, U as SELECTEUR_FLECHE_DEFILEMENT_DROITE, V as SELECTEUR_PHOTOS_PRODUIT, W as SELECTEUR_IMAGE_COLONNE_GAUCHE, X as SELECTEUR_IMAGES_COLONNE_DROITE, Y as ATTRIBUT_INDEX_IMAGE_ACTIVE } from "./dom.js";
|
||||||
import { r as recupereElementOuLeve, d as recupereElementsOuLeve, R as Ra } from "./dom2.js";
|
import { r as recupereElementOuLeve, d as recupereElementsOuLeve, R as Ra } from "./dom2.js";
|
||||||
import { l as leveServerError, r as reporteErreur } from "./erreurs.js";
|
import { l as leveServerError, r as reporteErreur } from "./erreurs.js";
|
||||||
import { b as estHTMLSelectElement, e as estReponse500, a as estError } from "./gardes.js";
|
import { b as estHTMLSelectElement, e as estReponse500, a as estError } from "./gardes.js";
|
||||||
|
|
@ -14,7 +14,7 @@ import { p as pipe } from "./pipe.XPB0wEfw.js";
|
||||||
import { l } from "./index-0eef19ec.CFsloYN6.js";
|
import { l } from "./index-0eef19ec.CFsloYN6.js";
|
||||||
import { M as Maybe } from "./Either.wHNxn7Os.js";
|
import { M as Maybe } from "./Either.wHNxn7Os.js";
|
||||||
import "./exports.DT-46nyp.js";
|
import "./exports.DT-46nyp.js";
|
||||||
import "./index.CXGAS3st.js";
|
import "./index.DeCaB8sW.js";
|
||||||
import "./messages3.js";
|
import "./messages3.js";
|
||||||
import "./messages2.js";
|
import "./messages2.js";
|
||||||
import "./erreurs2.js";
|
import "./erreurs2.js";
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import { p as parse } from "./index.CXGAS3st.js";
|
import { p as parse } from "./index.DeCaB8sW.js";
|
||||||
import { E as Either } from "./Either.wHNxn7Os.js";
|
import { E as Either } from "./Either.wHNxn7Os.js";
|
||||||
const eitherParse = (valeur, schema) => Either.encase(() => parse(schema, valeur));
|
const eitherParse = (valeur, schema) => Either.encase(() => parse(schema, valeur));
|
||||||
export {
|
export {
|
||||||
|
|
|
||||||
|
|
@ -17,9 +17,13 @@ $modeles = ["panier.twig"];
|
||||||
|
|
||||||
// Récupère les informations affichés des Produits du Panier
|
// Récupère les informations affichés des Produits du Panier
|
||||||
$panier = [];
|
$panier = [];
|
||||||
/** @var int Le sous-total de la Commande dans le Panier. */
|
/** @var int $sous_total_panier Le sous-total de la Commande dans le Panier. */
|
||||||
$sous_total_panier = pipe(WC()->cart->get_subtotal(), fn($sous_total) => intval($sous_total));
|
$sous_total_panier = pipe(WC()->cart->get_subtotal(), fn($sous_total) => intval($sous_total));
|
||||||
/** @var int Le total de la Commande dans le Panier. */
|
/** @var string|null $code_promo Le code promo appliqué au Panier s'il existe. */
|
||||||
|
$code_promo = collect(WC()->cart->get_applied_coupons())->first();
|
||||||
|
/** @var int $sous_total_reduction Le total du montant de la Réduction appliquée au Panier */
|
||||||
|
$sous_total_reduction = WC()->cart->get_totals()["discount_total"];
|
||||||
|
/** @var int $total_panier Le total de la Commande dans le Panier. */
|
||||||
$total_panier = pipe(WC()->cart->get_total(""), fn($total) => intval($total));
|
$total_panier = pipe(WC()->cart->get_total(""), fn($total) => intval($total));
|
||||||
|
|
||||||
foreach (WC()->cart->get_cart() as $cle_panier => $article_panier) {
|
foreach (WC()->cart->get_cart() as $cle_panier => $article_panier) {
|
||||||
|
|
@ -39,9 +43,12 @@ foreach (WC()->cart->get_cart() as $cle_panier => $article_panier) {
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
echo "<br><br><br><pre>";
|
// echo "<br><br><br><pre>";
|
||||||
print_r($panier);
|
// print_r($code_promo);
|
||||||
echo "</pre>";
|
// echo "<br>";
|
||||||
|
// print_r(WC()->cart->get_applied_coupons());
|
||||||
|
// print_r(WC()->cart->get_coupon_discount_totals());
|
||||||
|
// echo "</pre>";
|
||||||
|
|
||||||
// Récupère les Adresses de l'Utilisateur
|
// Récupère les Adresses de l'Utilisateur
|
||||||
$email = WC()->customer->get_billing_email();
|
$email = WC()->customer->get_billing_email();
|
||||||
|
|
@ -51,8 +58,10 @@ $adresse_facturation = WC()->customer->get_billing();
|
||||||
$contexte["email"] = $email;
|
$contexte["email"] = $email;
|
||||||
$contexte["adresse_livraison"] = $adresse_livraison;
|
$contexte["adresse_livraison"] = $adresse_livraison;
|
||||||
$contexte["adresse_facturation"] = $adresse_facturation;
|
$contexte["adresse_facturation"] = $adresse_facturation;
|
||||||
$contexte["total_panier"] = $total_panier;
|
|
||||||
$contexte["sous_total_panier"] = $sous_total_panier;
|
$contexte["sous_total_panier"] = $sous_total_panier;
|
||||||
|
$contexte["code_promo"] = $code_promo;
|
||||||
|
$contexte["sous_total_reduction"] = $sous_total_reduction;
|
||||||
|
$contexte["total_panier"] = $total_panier;
|
||||||
$contexte["produits_panier"] = $panier;
|
$contexte["produits_panier"] = $panier;
|
||||||
|
|
||||||
// Récupère les Pays pris en charge par WooCommerce
|
// Récupère les Pays pris en charge par WooCommerce
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,6 @@
|
||||||
|
|
||||||
/* Polices */
|
/* Polices */
|
||||||
--police-lato: "Lato", sans-serif;
|
--police-lato: "Lato", sans-serif;
|
||||||
--police-myriad: "Myriad", sans-serif;
|
|
||||||
|
|
||||||
/* Hauteurs de ligne */
|
/* Hauteurs de ligne */
|
||||||
--hauteur-ligne-classique: 1.5;
|
--hauteur-ligne-classique: 1.5;
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,9 @@
|
||||||
export const CHEMIN_API_REST = "wp-json";
|
export const CHEMIN_API_REST = "wp-json";
|
||||||
export const ROUTE_API_PANIER = `/${CHEMIN_API_REST}/wc/store/cart`;
|
export const ROUTE_API_PANIER = `/${CHEMIN_API_REST}/wc/store/cart`;
|
||||||
export const ROUTE_API_AJOUTE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/add-item`;
|
export const ROUTE_API_AJOUTE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/add-item`;
|
||||||
|
export const ROUTE_API_APPLIQUE_COUPON = `/${CHEMIN_API_REST}/wc/store/cart/apply-coupon`;
|
||||||
|
export const ROUTE_API_RETIRE_COUPON = `/${CHEMIN_API_REST}/wc/store/cart/remove-coupon`;
|
||||||
|
export const ROUTE_API_COUPONS = `/${CHEMIN_API_REST}/wc/store/cart/coupons`;
|
||||||
export const ROUTE_API_RETIRE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/remove-item`;
|
export const ROUTE_API_RETIRE_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/remove-item`;
|
||||||
export const ROUTE_API_MAJ_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/update-item`;
|
export const ROUTE_API_MAJ_ARTICLE_PANIER = `/${CHEMIN_API_REST}/wc/store/cart/update-item`;
|
||||||
export const ROUTE_API_MAJ_CLIENT = `/${CHEMIN_API_REST}/wc/store/cart/update-customer`;
|
export const ROUTE_API_MAJ_CLIENT = `/${CHEMIN_API_REST}/wc/store/cart/update-customer`;
|
||||||
|
|
|
||||||
|
|
@ -15,6 +15,7 @@ export const ATTRIBUT_ID_ENSEMBLE_EPINGLE_BOITE = "data-id-ensemble-epingle-boit
|
||||||
export const ATTRIBUT_ENSEMBLE_EPINGLE_BOITE_ACTIF = "data-ensemble-epingle-boite-actif";
|
export const ATTRIBUT_ENSEMBLE_EPINGLE_BOITE_ACTIF = "data-ensemble-epingle-boite-actif";
|
||||||
export const ATTRIBUT_INDEX_IMAGE_ACTIVE = "data-index-image-active";
|
export const ATTRIBUT_INDEX_IMAGE_ACTIVE = "data-index-image-active";
|
||||||
export const ATTRIBUT_PRIX = "data-prix";
|
export const ATTRIBUT_PRIX = "data-prix";
|
||||||
|
export const ATTRIBUT_CODE_PROMO_PRESENT = "data-code-promo-present";
|
||||||
|
|
||||||
// En-tête
|
// En-tête
|
||||||
export const SELECTEUR_BOUTON_MENU_MOBILE = "#bouton-menu-mobile";
|
export const SELECTEUR_BOUTON_MENU_MOBILE = "#bouton-menu-mobile";
|
||||||
|
|
@ -42,6 +43,8 @@ export const SELECTEUR_PRIX_LIGNE_PANIER = ".detail-produit__nom-prix span";
|
||||||
export const SELECTEUR_SOUS_TOTAL_PRODUITS = "#panneau-panier #sous-total-produits strong";
|
export const SELECTEUR_SOUS_TOTAL_PRODUITS = "#panneau-panier #sous-total-produits strong";
|
||||||
export const SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT = "#panneau-panier #sous-total-livraison strong";
|
export const SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT = "#panneau-panier #sous-total-livraison strong";
|
||||||
export const SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE = "#panneau-panier #sous-total-livraison span";
|
export const SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE = "#panneau-panier #sous-total-livraison span";
|
||||||
|
export const SELECTEUR_TOTAL_REDUCTION = "#panneau-panier #sous-total-reduction";
|
||||||
|
export const SELECTEUR_TOTAL_REDUCTION_VALEUR = "#panneau-panier #sous-total-reduction strong";
|
||||||
export const SELECTEUR_TOTAL_PANIER = "#panneau-panier .panneau__pied-de-page p span";
|
export const SELECTEUR_TOTAL_PANIER = "#panneau-panier .panneau__pied-de-page p span";
|
||||||
export const SELECTEUR_BOUTON_SEPARATION_ADRESSES = "#separation-adresses";
|
export const SELECTEUR_BOUTON_SEPARATION_ADRESSES = "#separation-adresses";
|
||||||
export const SELECTEUR_FORMULAIRE_PANIER = "#panneau-informations-client form";
|
export const SELECTEUR_FORMULAIRE_PANIER = "#panneau-informations-client form";
|
||||||
|
|
@ -49,6 +52,9 @@ export const SELECTEUR_FORMULAIRE_LIVRAISON = "#panneau-informations-client .pan
|
||||||
export const SELECTEUR_FORMULAIRE_FACTURATION = "#panneau-informations-client .panneau__formulaires__facturation";
|
export const SELECTEUR_FORMULAIRE_FACTURATION = "#panneau-informations-client .panneau__formulaires__facturation";
|
||||||
export const SELECTEUR_BOUTON_ACTIONS_FORMULAIRE = "#panneau-informations-client .panneau__pied-de-page button";
|
export const SELECTEUR_BOUTON_ACTIONS_FORMULAIRE = "#panneau-informations-client .panneau__pied-de-page button";
|
||||||
export const SELECTEUR_INSTRUCTIONS_CLIENT = "#panneau-panier #instructions-client";
|
export const SELECTEUR_INSTRUCTIONS_CLIENT = "#panneau-panier #instructions-client";
|
||||||
|
export const SELECTEUR_ENSEMBLE_CODE_PROMO = "#panneau-panier #ensemble-code-promo";
|
||||||
|
export const SELECTEUR_CHAMP_CODE_PROMO = "#panneau-panier #champ-code-promo";
|
||||||
|
export const SELECTEUR_BOUTON_CODE_PROMO = "#panneau-panier #bouton-code-promo";
|
||||||
|
|
||||||
// Accueil
|
// Accueil
|
||||||
export const SELECTEUR_CONTENEUR_STORYTELLING = ".storytelling";
|
export const SELECTEUR_CONTENEUR_STORYTELLING = ".storytelling";
|
||||||
|
|
|
||||||
|
|
@ -127,3 +127,9 @@ export const eitherSessionStorageGet = (cle: string): Either<NonExistingKeyError
|
||||||
*/
|
*/
|
||||||
export const eitherJsonParse = (chaine: string): Either<SyntaxError, JSONValue> =>
|
export const eitherJsonParse = (chaine: string): Either<SyntaxError, JSONValue> =>
|
||||||
Either.encase(() => JSON.parse(chaine));
|
Either.encase(() => JSON.parse(chaine));
|
||||||
|
|
||||||
|
/** TODO */
|
||||||
|
export const correspondCibleSelecteur = <E extends HTMLElement = HTMLElement>(
|
||||||
|
cible: EventTarget | null,
|
||||||
|
selecteur: string,
|
||||||
|
): cible is E => cible !== null && (cible as HTMLElement).matches(selecteur);
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,15 @@ type ArgumentsGetBackendWC = {
|
||||||
/** La route, ou chemin, de l'API à demander au backend. */
|
/** La route, ou chemin, de l'API à demander au backend. */
|
||||||
route: string;
|
route: string;
|
||||||
/** Paramètres de recherche (« query args ») à injecter dans l'URL de la requête. */
|
/** Paramètres de recherche (« query args ») à injecter dans l'URL de la requête. */
|
||||||
searchParams: string;
|
searchParams?: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
type ArgumentsDeleteBackendWC = {
|
||||||
|
authString?: string;
|
||||||
|
/** Une chaîne de caractères généré par le backend et à joindre à chaque requête pour l'authentifier. */
|
||||||
|
nonce: string;
|
||||||
|
/** La route, ou chemin, de l'API à demander au backend. */
|
||||||
|
route: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
type ArgumentsPostBackendWC = {
|
type ArgumentsPostBackendWC = {
|
||||||
|
|
@ -38,6 +46,24 @@ type ArgumentsPostBackendWC = {
|
||||||
};
|
};
|
||||||
|
|
||||||
export const getBackend = (args: ArgumentsGetBackendWC) =>
|
export const getBackend = (args: ArgumentsGetBackendWC) =>
|
||||||
|
fetch(
|
||||||
|
`${args.route}`,
|
||||||
|
{
|
||||||
|
credentials: "same-origin",
|
||||||
|
headers: {
|
||||||
|
Accept: "application/json",
|
||||||
|
"Content-Type": "application/json",
|
||||||
|
[ENTETE_WC_NONCE]: args.nonce,
|
||||||
|
// Ajoute conditionnellement l'en-tête « Authorization »
|
||||||
|
...(args.authString && { Authorization: `Basic ${args.authString}` }),
|
||||||
|
},
|
||||||
|
method: "GET",
|
||||||
|
mode: "same-origin",
|
||||||
|
signal: AbortSignal.timeout(5000),
|
||||||
|
},
|
||||||
|
);
|
||||||
|
|
||||||
|
export const getBackendAvecParametresUrl = (args: ArgumentsGetBackendWC) =>
|
||||||
fetch(
|
fetch(
|
||||||
`${args.route}?${args.searchParams}`,
|
`${args.route}?${args.searchParams}`,
|
||||||
{
|
{
|
||||||
|
|
@ -55,6 +81,24 @@ export const getBackend = (args: ArgumentsGetBackendWC) =>
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
|
|
||||||
|
export const deleteBackend = (args: ArgumentsDeleteBackendWC) =>
|
||||||
|
fetch(
|
||||||
|
args.route,
|
||||||
|
{
|
||||||
|
credentials: "same-origin",
|
||||||
|
headers: {
|
||||||
|
Accept: "application/json",
|
||||||
|
"Content-Type": "application/json",
|
||||||
|
[ENTETE_WC_NONCE]: args.nonce,
|
||||||
|
// Ajoute conditionnellement l'en-tête « Authorization »
|
||||||
|
...(args.authString && { Authorization: `Basic ${args.authString}` }),
|
||||||
|
},
|
||||||
|
method: "DELETE",
|
||||||
|
mode: "same-origin",
|
||||||
|
signal: AbortSignal.timeout(5000),
|
||||||
|
},
|
||||||
|
);
|
||||||
|
|
||||||
export const postBackend = (args: ArgumentsPostBackendWC) =>
|
export const postBackend = (args: ArgumentsPostBackendWC) =>
|
||||||
fetch(
|
fetch(
|
||||||
args.route,
|
args.route,
|
||||||
|
|
@ -90,8 +134,14 @@ export const traiteReponseBackendWCSelonCodesHTTP = <R, S extends GenericSchema<
|
||||||
// Réponses inconnues
|
// Réponses inconnues
|
||||||
.otherwise(e => pipe(e, ErreurInconnue, leveErreur<UnknownError>));
|
.otherwise(e => pipe(e, ErreurInconnue, leveErreur<UnknownError>));
|
||||||
|
|
||||||
type TraitementReponseBackend<R, S extends GenericSchema<R>> = Either<
|
export type TraitementReponseBackendErrors<R, S extends GenericSchema<R>> =
|
||||||
BadRequestError | NotFoundError | UnauthorizedError | UnknownError | ValiError<S>,
|
| BadRequestError
|
||||||
|
| NotFoundError
|
||||||
|
| UnauthorizedError
|
||||||
|
| UnknownError
|
||||||
|
| ValiError<S>;
|
||||||
|
export type TraitementReponseBackend<R, S extends GenericSchema<R>> = Either<
|
||||||
|
TraitementReponseBackendErrors<R, S>,
|
||||||
R
|
R
|
||||||
>;
|
>;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,6 @@
|
||||||
|
import * as v from "valibot";
|
||||||
|
|
||||||
|
export const WCStoreCartApplyCouponArgsSchema = v.object({
|
||||||
|
/** Unique identifier for the coupon within the basket */
|
||||||
|
code: v.optional(v.string()),
|
||||||
|
});
|
||||||
|
|
@ -0,0 +1,34 @@
|
||||||
|
import * as v from "valibot";
|
||||||
|
|
||||||
|
export const WCStoreCartCouponsArgSchema = v.object({
|
||||||
|
// Unique identifier for the coupon within the basket.
|
||||||
|
code: v.string(),
|
||||||
|
});
|
||||||
|
|
||||||
|
export const WCStoreCartCouponsSchema = v.object({
|
||||||
|
// The coupon's unique code.
|
||||||
|
code: v.string(),
|
||||||
|
// The discount type for the coupon (eg percentage or fixed amount)
|
||||||
|
discount_type: v.string(),
|
||||||
|
// Total amounts provided using the smallest unit of the currency.
|
||||||
|
totals: v.object({
|
||||||
|
// Currency code (in ISO format) for returned prices.
|
||||||
|
currency_code: v.string(),
|
||||||
|
// Currency symbol for the currency which can be used to format returned prices.
|
||||||
|
currency_symbol: v.string(),
|
||||||
|
// Currency minor unit (number of digits after the decimal separator) for returned prices.
|
||||||
|
currency_minor_unit: v.pipe(v.number(), v.integer()),
|
||||||
|
// Decimal separator for the currency which can be used to format returned prices.
|
||||||
|
currency_decimal_separator: v.string(),
|
||||||
|
// Thousand separator for the currency which can be used to format returned prices.
|
||||||
|
currency_thousand_separator: v.string(),
|
||||||
|
// Price prefix for the currency which can be used to format returned prices.
|
||||||
|
currency_prefix: v.string(),
|
||||||
|
// Price prefix for the currency which can be used to format returned prices.
|
||||||
|
currency_suffix: v.string(),
|
||||||
|
// Total discount applied by this coupon.
|
||||||
|
total_discount: v.string(),
|
||||||
|
// Total tax removed due to discount applied by this coupon.
|
||||||
|
total_discount_tax: v.string(),
|
||||||
|
}),
|
||||||
|
});
|
||||||
|
|
@ -0,0 +1,6 @@
|
||||||
|
import * as v from "valibot";
|
||||||
|
|
||||||
|
export const WCStoreCartRemoveCouponArgsSchema = v.object({
|
||||||
|
/** Unique identifier for the coupon within the basket */
|
||||||
|
code: v.optional(v.string()),
|
||||||
|
});
|
||||||
4
web/app/themes/haiku-atelier-2024/src/scripts/lib/types/api/cart-apply-coupon.d.ts
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
||||||
|
import type { InferOutput } from "valibot";
|
||||||
|
import type { WCStoreCartApplyCouponArgsSchema } from "../../schemas/api/cart-apply-coupon";
|
||||||
|
|
||||||
|
export type WCStoreCartApplyCouponArgs = InferOutput<typeof WCStoreCartApplyCouponArgsSchema>;
|
||||||
6
web/app/themes/haiku-atelier-2024/src/scripts/lib/types/api/cart-coupons.d.ts
vendored
Normal file
|
|
@ -0,0 +1,6 @@
|
||||||
|
import type { InferOutput } from "valibot";
|
||||||
|
import type { WCStoreCartApplyCouponArgsSchema } from "../../schemas/api/cart-apply-coupon";
|
||||||
|
import type { WCStoreCartCouponsSchema } from "../../schemas/api/cart-coupons";
|
||||||
|
|
||||||
|
export type WCStoreCartCouponsArgs = InferOutput<typeof WCStoreCartApplyCouponArgsSchema>;
|
||||||
|
export type WCStoreCartCoupons = InferOutput<typeof WCStoreCartCouponsSchema>;
|
||||||
4
web/app/themes/haiku-atelier-2024/src/scripts/lib/types/api/cart-remove-coupon.d.ts
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
||||||
|
import type { InferOutput } from "valibot";
|
||||||
|
import type { WCStoreCartRemoveCouponArgsSchema } from "../../schemas/api/cart-remove-coupon";
|
||||||
|
|
||||||
|
export type WCStoreCartRemoveCouponArgs = InferOutput<typeof WCStoreCartRemoveCouponArgsSchema>;
|
||||||
|
|
@ -23,7 +23,7 @@ import {
|
||||||
import { html } from "./lib/dom.ts";
|
import { html } from "./lib/dom.ts";
|
||||||
import { leveServerError } from "./lib/erreurs.ts";
|
import { leveServerError } from "./lib/erreurs.ts";
|
||||||
import { estReponse500 } from "./lib/gardes.ts";
|
import { estReponse500 } from "./lib/gardes.ts";
|
||||||
import { getBackend, traiteReponseBackendWCSelonCodesHTTP } from "./lib/reseau.ts";
|
import { getBackendAvecParametresUrl, traiteReponseBackendWCSelonCodesHTTP } from "./lib/reseau.ts";
|
||||||
import { WCV3ProductsSchema } from "./lib/schemas/api/v3/products.ts";
|
import { WCV3ProductsSchema } from "./lib/schemas/api/v3/products.ts";
|
||||||
import { WCV3ProductsArgsSchema } from "./lib/schemas/api/v3/products.ts";
|
import { WCV3ProductsArgsSchema } from "./lib/schemas/api/v3/products.ts";
|
||||||
import { recupereElementDansDocumentOuLeve, recupereElementDocumentEither } from "./lib/utils.ts";
|
import { recupereElementDansDocumentOuLeve, recupereElementDocumentEither } from "./lib/utils.ts";
|
||||||
|
|
@ -74,7 +74,7 @@ const initialisePageBoutique = (): void => {
|
||||||
async (args: WCProductsArgs) => {
|
async (args: WCProductsArgs) => {
|
||||||
// Réalise la requête
|
// Réalise la requête
|
||||||
await EitherAsync<APIProductsErrors, Response>(() =>
|
await EitherAsync<APIProductsErrors, Response>(() =>
|
||||||
getBackend({
|
getBackendAvecParametresUrl({
|
||||||
authString: ETATS_PAGE.authString,
|
authString: ETATS_PAGE.authString,
|
||||||
nonce: ETATS_PAGE.nonce,
|
nonce: ETATS_PAGE.nonce,
|
||||||
route: ROUTE_API_NOUVELLE_PRODUCTS,
|
route: ROUTE_API_NOUVELLE_PRODUCTS,
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,71 @@
|
||||||
|
/**
|
||||||
|
* Scripts pour la gestion des codes promos (coupons) sur la Page Panier.
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { Maybe } from "purify-ts";
|
||||||
|
import { match, P } from "ts-pattern";
|
||||||
|
import {
|
||||||
|
ATTRIBUT_CODE_PROMO_PRESENT,
|
||||||
|
SELECTEUR_BOUTON_CODE_PROMO,
|
||||||
|
SELECTEUR_CHAMP_CODE_PROMO,
|
||||||
|
SELECTEUR_ENSEMBLE_CODE_PROMO,
|
||||||
|
SELECTEUR_TOTAL_REDUCTION,
|
||||||
|
SELECTEUR_TOTAL_REDUCTION_VALEUR,
|
||||||
|
} from "./constantes/dom";
|
||||||
|
import { correspondCibleSelecteur } from "./lib/dom";
|
||||||
|
import { recupereElementDansDocumentOuLeve } from "./lib/utils";
|
||||||
|
|
||||||
|
/** États utiles pour les scripts de la page. */
|
||||||
|
type EtatsPage = {
|
||||||
|
authString: string;
|
||||||
|
/** Un nonce pour l'authentification de requêtes API vers le backend WooCommerce. */
|
||||||
|
nonce: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
// @ts-expect-error -- États injectés par le modèle PHP
|
||||||
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment -- États injectés par le modèle PHP
|
||||||
|
const ETATS_PAGE: EtatsPage = _etats;
|
||||||
|
|
||||||
|
const ELEMENTS = {
|
||||||
|
TOTAL_REDUCTION_LIGNE: recupereElementDansDocumentOuLeve<HTMLDivElement>(SELECTEUR_TOTAL_REDUCTION),
|
||||||
|
TOTAL_REDUCTION_VALEUR: recupereElementDansDocumentOuLeve<HTMLSpanElement>(SELECTEUR_TOTAL_REDUCTION_VALEUR),
|
||||||
|
ENSEMBLE_CODE_PROMO: recupereElementDansDocumentOuLeve<HTMLDivElement>(SELECTEUR_ENSEMBLE_CODE_PROMO),
|
||||||
|
CHAMP_CODE_PROMO: recupereElementDansDocumentOuLeve<HTMLInputElement>(SELECTEUR_CHAMP_CODE_PROMO),
|
||||||
|
BOUTON_CODE_PROMO: recupereElementDansDocumentOuLeve<HTMLButtonElement>(SELECTEUR_BOUTON_CODE_PROMO),
|
||||||
|
};
|
||||||
|
|
||||||
|
const initialiseElementsCodePromo = (): void => {
|
||||||
|
// Récupère la présence s'il existe
|
||||||
|
const recupereCodePromo = (): null | string =>
|
||||||
|
Maybe
|
||||||
|
.fromFalsy(ELEMENTS.ENSEMBLE_CODE_PROMO.hasAttribute(ATTRIBUT_CODE_PROMO_PRESENT))
|
||||||
|
.chain(() => Maybe.fromNullable(ELEMENTS.CHAMP_CODE_PROMO.value))
|
||||||
|
.extractNullable();
|
||||||
|
|
||||||
|
// Créé la délégation d'Événements
|
||||||
|
ELEMENTS.ENSEMBLE_CODE_PROMO.addEventListener("click", (evenement: Event) => {
|
||||||
|
match({
|
||||||
|
codePromo: recupereCodePromo(),
|
||||||
|
cible: evenement.target,
|
||||||
|
})
|
||||||
|
.with(
|
||||||
|
{
|
||||||
|
codePromo: P.string,
|
||||||
|
cible: P.when(cible => correspondCibleSelecteur<HTMLButtonElement>(cible, SELECTEUR_BOUTON_CODE_PROMO)),
|
||||||
|
},
|
||||||
|
v => {
|
||||||
|
console.debug(v);
|
||||||
|
},
|
||||||
|
)
|
||||||
|
// Ne rien faire en cas de code promo absent
|
||||||
|
.with(
|
||||||
|
{
|
||||||
|
codePromo: P.nullish,
|
||||||
|
cible: P.when(cible => correspondCibleSelecteur<HTMLButtonElement>(cible, SELECTEUR_BOUTON_CODE_PROMO)),
|
||||||
|
},
|
||||||
|
v => {
|
||||||
|
console.debug(v);
|
||||||
|
},
|
||||||
|
);
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { D, F, pipe } from "@mobily/ts-belt";
|
import { D, F, pipe } from "@mobily/ts-belt";
|
||||||
import { Either, Maybe } from "purify-ts";
|
import { Either, EitherAsync, Maybe } from "purify-ts";
|
||||||
import { match } from "ts-pattern";
|
import { match, P } from "ts-pattern";
|
||||||
import { parse, ValiError } from "valibot";
|
import { parse, ValiError } from "valibot";
|
||||||
|
|
||||||
import type { MessageMajContenuPanierSchema } from "./lib/schemas/messages.ts";
|
import type { MessageMajContenuPanierSchema } from "./lib/schemas/messages.ts";
|
||||||
|
|
@ -12,23 +12,29 @@ import type { WCV3Order, WCV3OrdersArgs } from "./lib/types/api/v3/orders.ts";
|
||||||
import type { MessageMajBoutonPanierDonnees, MessageMajContenuPanierDonnees } from "./lib/types/messages";
|
import type { MessageMajBoutonPanierDonnees, MessageMajContenuPanierDonnees } from "./lib/types/messages";
|
||||||
|
|
||||||
import {
|
import {
|
||||||
|
ROUTE_API_APPLIQUE_COUPON,
|
||||||
ROUTE_API_MAJ_ARTICLE_PANIER,
|
ROUTE_API_MAJ_ARTICLE_PANIER,
|
||||||
ROUTE_API_MAJ_CLIENT,
|
ROUTE_API_MAJ_CLIENT,
|
||||||
ROUTE_API_NOUVELLE_COMMANDES,
|
ROUTE_API_NOUVELLE_COMMANDES,
|
||||||
ROUTE_API_RETIRE_ARTICLE_PANIER,
|
ROUTE_API_RETIRE_ARTICLE_PANIER,
|
||||||
|
ROUTE_API_RETIRE_COUPON,
|
||||||
} from "./constantes/api.ts";
|
} from "./constantes/api.ts";
|
||||||
import {
|
import {
|
||||||
ATTRIBUT_CLE_PANIER,
|
ATTRIBUT_CLE_PANIER,
|
||||||
|
ATTRIBUT_CODE_PROMO_PRESENT,
|
||||||
ATTRIBUT_CONTIENT_ARTICLES,
|
ATTRIBUT_CONTIENT_ARTICLES,
|
||||||
ATTRIBUT_DESACTIVE,
|
ATTRIBUT_DESACTIVE,
|
||||||
ATTRIBUT_HIDDEN,
|
ATTRIBUT_HIDDEN,
|
||||||
SELECTEUR_BOUTON_ACTIONS_FORMULAIRE,
|
SELECTEUR_BOUTON_ACTIONS_FORMULAIRE,
|
||||||
SELECTEUR_BOUTON_ADDITION_QUANTITE,
|
SELECTEUR_BOUTON_ADDITION_QUANTITE,
|
||||||
|
SELECTEUR_BOUTON_CODE_PROMO,
|
||||||
SELECTEUR_BOUTON_SEPARATION_ADRESSES,
|
SELECTEUR_BOUTON_SEPARATION_ADRESSES,
|
||||||
SELECTEUR_BOUTON_SOUSTRACTION_QUANTITE,
|
SELECTEUR_BOUTON_SOUSTRACTION_QUANTITE,
|
||||||
SELECTEUR_BOUTON_SUPPRESSION_PANIER,
|
SELECTEUR_BOUTON_SUPPRESSION_PANIER,
|
||||||
|
SELECTEUR_CHAMP_CODE_PROMO,
|
||||||
SELECTEUR_CHAMP_QUANTITE_LIGNE_PANIER,
|
SELECTEUR_CHAMP_QUANTITE_LIGNE_PANIER,
|
||||||
SELECTEUR_CONTENEUR_PANIER,
|
SELECTEUR_CONTENEUR_PANIER,
|
||||||
|
SELECTEUR_ENSEMBLE_CODE_PROMO,
|
||||||
SELECTEUR_ENTREES_PANIER,
|
SELECTEUR_ENTREES_PANIER,
|
||||||
SELECTEUR_FORMULAIRE_FACTURATION,
|
SELECTEUR_FORMULAIRE_FACTURATION,
|
||||||
SELECTEUR_FORMULAIRE_PANIER,
|
SELECTEUR_FORMULAIRE_PANIER,
|
||||||
|
|
@ -37,6 +43,8 @@ import {
|
||||||
SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT,
|
SELECTEUR_SOUS_TOTAL_LIVRAISON_COUT,
|
||||||
SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE,
|
SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE,
|
||||||
SELECTEUR_SOUS_TOTAL_PRODUITS,
|
SELECTEUR_SOUS_TOTAL_PRODUITS,
|
||||||
|
SELECTEUR_TOTAL_REDUCTION,
|
||||||
|
SELECTEUR_TOTAL_REDUCTION_VALEUR,
|
||||||
SELECTEUR_TOTAL_PANIER,
|
SELECTEUR_TOTAL_PANIER,
|
||||||
} from "./constantes/dom.ts";
|
} from "./constantes/dom.ts";
|
||||||
import { NOM_CANAL_BOUTON_PANIER, NOM_CANAL_CONTENU_PANIER } from "./constantes/messages.ts";
|
import { NOM_CANAL_BOUTON_PANIER, NOM_CANAL_CONTENU_PANIER } from "./constantes/messages.ts";
|
||||||
|
|
@ -47,7 +55,7 @@ import {
|
||||||
recupereElementOuLeve,
|
recupereElementOuLeve,
|
||||||
recupereElementsAvecSelecteur,
|
recupereElementsAvecSelecteur,
|
||||||
} from "./lib/dom.ts";
|
} from "./lib/dom.ts";
|
||||||
import { type CleNonTrouveError, leveErreur, leveServerError, reporteErreur } from "./lib/erreurs.ts";
|
import { type CleNonTrouveError, leveErreur, leveServerError, reporteErreur, ServerError } from "./lib/erreurs.ts";
|
||||||
import { estError, estReponse500 } from "./lib/gardes.ts";
|
import { estError, estReponse500 } from "./lib/gardes.ts";
|
||||||
import {
|
import {
|
||||||
emetMessageMajBoutonPanier,
|
emetMessageMajBoutonPanier,
|
||||||
|
|
@ -56,12 +64,16 @@ import {
|
||||||
valideMessageMajContenuPanier,
|
valideMessageMajContenuPanier,
|
||||||
} from "./lib/messages.ts";
|
} from "./lib/messages.ts";
|
||||||
import { postBackend, traiteReponseBackendWCSelonCodesHTTP } from "./lib/reseau.ts";
|
import { postBackend, traiteReponseBackendWCSelonCodesHTTP } from "./lib/reseau.ts";
|
||||||
|
import { WCStoreCartApplyCouponArgsSchema } from "./lib/schemas/api/cart-apply-coupon.ts";
|
||||||
|
import { WCStoreCartRemoveCouponArgsSchema } from "./lib/schemas/api/cart-remove-coupon.ts";
|
||||||
import { WCStoreCartRemoveItemArgsSchema } from "./lib/schemas/api/cart-remove-item.ts";
|
import { WCStoreCartRemoveItemArgsSchema } from "./lib/schemas/api/cart-remove-item.ts";
|
||||||
import { WCStoreCartUpdateCustomerArgsSchema } from "./lib/schemas/api/cart-update-customer.ts";
|
import { WCStoreCartUpdateCustomerArgsSchema } from "./lib/schemas/api/cart-update-customer.ts";
|
||||||
import { WCStoreCartUpdateItemArgsSchema } from "./lib/schemas/api/cart-update-item.ts";
|
import { WCStoreCartUpdateItemArgsSchema } from "./lib/schemas/api/cart-update-item.ts";
|
||||||
import { WCStoreCartSchema } from "./lib/schemas/api/cart.ts";
|
import { WCStoreCartSchema } from "./lib/schemas/api/cart.ts";
|
||||||
import { WCStoreShippingRateShippingRateSchema } from "./lib/schemas/api/couts-livraison.ts";
|
import { WCStoreShippingRateShippingRateSchema } from "./lib/schemas/api/couts-livraison.ts";
|
||||||
import { WCV3OrdersArgsSchema, WCV3OrderSchema } from "./lib/schemas/api/v3/orders.ts";
|
import { WCV3OrdersArgsSchema, WCV3OrderSchema } from "./lib/schemas/api/v3/orders.ts";
|
||||||
|
import type { WCStoreCartApplyCouponArgs } from "./lib/types/api/cart-apply-coupon";
|
||||||
|
import type { WCStoreCartRemoveCouponArgs } from "./lib/types/api/cart-remove-coupon";
|
||||||
import {
|
import {
|
||||||
propEither,
|
propEither,
|
||||||
recupereElementDansDocumentOuLeve,
|
recupereElementDansDocumentOuLeve,
|
||||||
|
|
@ -108,7 +120,11 @@ const SOUS_TOTAL_LIVRAISON_PRESTATAIRE: HTMLSpanElement = pipe(
|
||||||
recupereElementDocumentEither<HTMLSpanElement>(SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE),
|
recupereElementDocumentEither<HTMLSpanElement>(SELECTEUR_SOUS_TOTAL_LIVRAISON_PRESTATAIRE),
|
||||||
recupereElementOuLeve,
|
recupereElementOuLeve,
|
||||||
);
|
);
|
||||||
const INSTRUCTIONS_CLIENT: HTMLTextAreaElement = recupereElementDansDocumentOuLeve<HTMLTextAreaElement>(
|
const SOUS_TOTAL_REDUCTION_LIGNE: HTMLDivElement = recupereElementDansDocumentOuLeve(SELECTEUR_TOTAL_REDUCTION);
|
||||||
|
const SOUS_TOTAL_REDUCTION_VALEUR: HTMLSpanElement = recupereElementDansDocumentOuLeve(
|
||||||
|
SELECTEUR_TOTAL_REDUCTION_VALEUR,
|
||||||
|
);
|
||||||
|
const INSTRUCTIONS_CLIENT: HTMLTextAreaElement = recupereElementDansDocumentOuLeve(
|
||||||
SELECTEUR_INSTRUCTIONS_CLIENT,
|
SELECTEUR_INSTRUCTIONS_CLIENT,
|
||||||
);
|
);
|
||||||
const TOTAL_PANIER: HTMLParagraphElement = pipe(
|
const TOTAL_PANIER: HTMLParagraphElement = pipe(
|
||||||
|
|
@ -119,14 +135,19 @@ const BOUTON_SEPARATION_ADRESSES: HTMLInputElement = pipe(
|
||||||
recupereElementDocumentEither<HTMLInputElement>(SELECTEUR_BOUTON_SEPARATION_ADRESSES),
|
recupereElementDocumentEither<HTMLInputElement>(SELECTEUR_BOUTON_SEPARATION_ADRESSES),
|
||||||
recupereElementOuLeve,
|
recupereElementOuLeve,
|
||||||
);
|
);
|
||||||
|
const ENSEMBLE_CODE_PROMO: HTMLDivElement = recupereElementDansDocumentOuLeve(
|
||||||
|
SELECTEUR_ENSEMBLE_CODE_PROMO,
|
||||||
|
);
|
||||||
|
const CHAMP_CODE_PROMO: HTMLInputElement = recupereElementDansDocumentOuLeve(
|
||||||
|
SELECTEUR_CHAMP_CODE_PROMO,
|
||||||
|
);
|
||||||
|
let BOUTON_CODE_PROMO: HTMLButtonElement = recupereElementDansDocumentOuLeve(
|
||||||
|
SELECTEUR_BOUTON_CODE_PROMO,
|
||||||
|
);
|
||||||
const FORMULAIRE_PANIER: HTMLFormElement = pipe(
|
const FORMULAIRE_PANIER: HTMLFormElement = pipe(
|
||||||
recupereElementDocumentEither<HTMLFormElement>(SELECTEUR_FORMULAIRE_PANIER),
|
recupereElementDocumentEither<HTMLFormElement>(SELECTEUR_FORMULAIRE_PANIER),
|
||||||
recupereElementOuLeve,
|
recupereElementOuLeve,
|
||||||
);
|
);
|
||||||
// const FORMULAIRE_LIVRAISON: HTMLDivElement = pipe(
|
|
||||||
// recupereElementDocumentEither<HTMLDivElement>(SELECTEUR_FORMULAIRE_LIVRAISON),
|
|
||||||
// recupereElementOuLeve,
|
|
||||||
// );
|
|
||||||
const FORMULAIRE_FACTURATION: HTMLDivElement = pipe(
|
const FORMULAIRE_FACTURATION: HTMLDivElement = pipe(
|
||||||
recupereElementDocumentEither<HTMLDivElement>(SELECTEUR_FORMULAIRE_FACTURATION),
|
recupereElementDocumentEither<HTMLDivElement>(SELECTEUR_FORMULAIRE_FACTURATION),
|
||||||
recupereElementOuLeve,
|
recupereElementOuLeve,
|
||||||
|
|
@ -262,7 +283,7 @@ const initialiseMajEntreesPanier = (): void => {
|
||||||
});
|
});
|
||||||
|
|
||||||
// Retire une unité à une ligne du Panier au clic sur le bouton de soustraction
|
// Retire une unité à une ligne du Panier au clic sur le bouton de soustraction
|
||||||
boutonSoustraction.addEventListener("click", (evenement: Event): void => {
|
boutonSoustraction.addEventListener("click", (): void => {
|
||||||
Maybe.fromNullable(champQuantite.valueAsNumber)
|
Maybe.fromNullable(champQuantite.valueAsNumber)
|
||||||
.filter(valeur => valeur > 1)
|
.filter(valeur => valeur > 1)
|
||||||
.ifJust(valeur => {
|
.ifJust(valeur => {
|
||||||
|
|
@ -412,7 +433,7 @@ const initialiseMajContenuPanier = (): void => {
|
||||||
|
|
||||||
// Met à jour les valeurs
|
// Met à jour les valeurs
|
||||||
entree.setAttribute("data-quantite", String(ligne.quantity));
|
entree.setAttribute("data-quantite", String(ligne.quantity));
|
||||||
prixLigne.textContent = `${String(Number(ligne.totals.line_total) / 100)}€`;
|
prixLigne.textContent = `${String(Number(ligne.totals.line_subtotal) / 100)}€`;
|
||||||
champQuantite.setAttribute("value", String(ligne.quantity));
|
champQuantite.setAttribute("value", String(ligne.quantity));
|
||||||
|
|
||||||
// Réactive les Boutons
|
// Réactive les Boutons
|
||||||
|
|
@ -563,6 +584,130 @@ const initialiseBoutonActions = (): void => {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const initialiseElementsCodePromo = (): void => {
|
||||||
|
// Récupérer un code promo assigné au Panier s'il existe
|
||||||
|
const codePromoPresent = ENSEMBLE_CODE_PROMO.hasAttribute(ATTRIBUT_CODE_PROMO_PRESENT);
|
||||||
|
|
||||||
|
BOUTON_CODE_PROMO.outerHTML = BOUTON_CODE_PROMO.outerHTML;
|
||||||
|
BOUTON_CODE_PROMO = recupereElementDansDocumentOuLeve(SELECTEUR_BOUTON_CODE_PROMO);
|
||||||
|
|
||||||
|
// Au clic, retire le code promo présent
|
||||||
|
if (codePromoPresent) {
|
||||||
|
BOUTON_CODE_PROMO.addEventListener("click", () => {
|
||||||
|
const code = CHAMP_CODE_PROMO.value;
|
||||||
|
|
||||||
|
EitherAsync
|
||||||
|
.liftEither(eitherParse<typeof WCStoreCartRemoveCouponArgsSchema>({ code }, WCStoreCartRemoveCouponArgsSchema))
|
||||||
|
.map((args: WCStoreCartRemoveCouponArgs) =>
|
||||||
|
postBackend({
|
||||||
|
corps: JSON.stringify(args),
|
||||||
|
nonce: ETATS_PAGE.nonce,
|
||||||
|
route: ROUTE_API_RETIRE_COUPON,
|
||||||
|
})
|
||||||
|
)
|
||||||
|
// Traite le cas d'une erreur 500 et récupère le corps de la Réponse
|
||||||
|
.chain(async (reponse: Response) =>
|
||||||
|
EitherAsync<ServerError, unknown>(async ({ throwE }) => {
|
||||||
|
if (estReponse500(reponse)) throwE(new ServerError("500 Server Error"));
|
||||||
|
return await reponse.json();
|
||||||
|
})
|
||||||
|
)
|
||||||
|
// Vérifie le schéma de la Réponse
|
||||||
|
.chain((corpsReponse: unknown) =>
|
||||||
|
EitherAsync<ValiError<typeof WCStoreCartSchema>, WCStoreCart>(({ liftEither }) =>
|
||||||
|
liftEither(eitherParse(corpsReponse, WCStoreCartSchema))
|
||||||
|
)
|
||||||
|
)
|
||||||
|
.ifRight((panier: WCStoreCart) => {
|
||||||
|
const totalPanier: string = `${String(Number(panier.totals.total_price) / 100)}€`;
|
||||||
|
|
||||||
|
ENSEMBLE_CODE_PROMO.removeAttribute(ATTRIBUT_CODE_PROMO_PRESENT);
|
||||||
|
BOUTON_CODE_PROMO.textContent = "Apply";
|
||||||
|
CHAMP_CODE_PROMO.value = "";
|
||||||
|
CHAMP_CODE_PROMO.toggleAttribute(ATTRIBUT_DESACTIVE);
|
||||||
|
|
||||||
|
TOTAL_PANIER.textContent = totalPanier;
|
||||||
|
SOUS_TOTAL_REDUCTION_VALEUR.textContent = "-0€";
|
||||||
|
SOUS_TOTAL_REDUCTION_LIGNE.setAttribute(ATTRIBUT_HIDDEN, "");
|
||||||
|
|
||||||
|
initialiseElementsCodePromo();
|
||||||
|
})
|
||||||
|
.ifLeft(e => {
|
||||||
|
console.error("requête", e);
|
||||||
|
if (e instanceof ValiError) console.error(e.issues);
|
||||||
|
})
|
||||||
|
.run();
|
||||||
|
});
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Au clic, ajoute le code promo demandé
|
||||||
|
BOUTON_CODE_PROMO.addEventListener("click", () => {
|
||||||
|
// Récupère le code promo du champ et valide sa forme
|
||||||
|
const codePromo: Either<
|
||||||
|
TypeError | ValiError<typeof WCStoreCartApplyCouponArgsSchema>,
|
||||||
|
WCStoreCartApplyCouponArgs
|
||||||
|
> = Maybe
|
||||||
|
.fromFalsy(CHAMP_CODE_PROMO.value.trim())
|
||||||
|
// Transforme le Maybe en Either avec à Gauche une Erreur en cas d'absence de valeur, à Droite le code renseigné
|
||||||
|
.toEither(new TypeError("Aucun code promo n'a été renseigné."))
|
||||||
|
.chain((code: string) => eitherParse({ code }, WCStoreCartApplyCouponArgsSchema))
|
||||||
|
.ifRight((args: WCStoreCartApplyCouponArgs) => console.debug(args))
|
||||||
|
// Traitement différencié des Erreurs
|
||||||
|
.ifLeft(erreur =>
|
||||||
|
match(erreur)
|
||||||
|
.with(P.instanceOf(ValiError), e => console.error("codePromo", e.issues))
|
||||||
|
.with(P.instanceOf(TypeError), e => console.error("codePromo", e))
|
||||||
|
.exhaustive()
|
||||||
|
);
|
||||||
|
|
||||||
|
EitherAsync
|
||||||
|
.liftEither(codePromo)
|
||||||
|
// Réalise la requête
|
||||||
|
.map(async args =>
|
||||||
|
await postBackend({
|
||||||
|
corps: JSON.stringify(args),
|
||||||
|
nonce: ETATS_PAGE.nonce,
|
||||||
|
route: ROUTE_API_APPLIQUE_COUPON,
|
||||||
|
})
|
||||||
|
)
|
||||||
|
// Traite le cas d'une erreur 500 et récupère le corps de la Réponse
|
||||||
|
.chain(async (reponse: Response) =>
|
||||||
|
EitherAsync<ServerError, unknown>(async ({ throwE }) => {
|
||||||
|
if (estReponse500(reponse)) throwE(new ServerError("500 Server Error"));
|
||||||
|
return await reponse.json();
|
||||||
|
})
|
||||||
|
)
|
||||||
|
// Vérifie le schéma de la Réponse
|
||||||
|
.chain((corpsReponse: unknown) =>
|
||||||
|
EitherAsync<ValiError<typeof WCStoreCartSchema>, WCStoreCart>(({ liftEither }) =>
|
||||||
|
liftEither(eitherParse(corpsReponse, WCStoreCartSchema))
|
||||||
|
)
|
||||||
|
)
|
||||||
|
.ifRight((panier: WCStoreCart) => {
|
||||||
|
const totalReduction: string = `-${String(Number(panier.totals.total_discount) / 100)}€`;
|
||||||
|
const totalPanier: string = `${Number(panier.totals.total_price) / 100}€`;
|
||||||
|
|
||||||
|
ENSEMBLE_CODE_PROMO.setAttribute(ATTRIBUT_CODE_PROMO_PRESENT, "");
|
||||||
|
BOUTON_CODE_PROMO.textContent = "Remove";
|
||||||
|
CHAMP_CODE_PROMO.value = panier.coupons[0].code;
|
||||||
|
CHAMP_CODE_PROMO.toggleAttribute(ATTRIBUT_DESACTIVE);
|
||||||
|
|
||||||
|
TOTAL_PANIER.textContent = totalPanier;
|
||||||
|
SOUS_TOTAL_REDUCTION_VALEUR.textContent = totalReduction;
|
||||||
|
SOUS_TOTAL_REDUCTION_LIGNE.removeAttribute(ATTRIBUT_HIDDEN);
|
||||||
|
|
||||||
|
initialiseElementsCodePromo();
|
||||||
|
})
|
||||||
|
.ifLeft(e => {
|
||||||
|
console.error("requête", e);
|
||||||
|
if (e instanceof ValiError) console.error(e.issues);
|
||||||
|
})
|
||||||
|
.run();
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
const initialiseBoutonCreationCommande = (): void => {
|
const initialiseBoutonCreationCommande = (): void => {
|
||||||
// Permet de supprimer tout Écouteur d'Évènement assigné au Bouton
|
// Permet de supprimer tout Écouteur d'Évènement assigné au Bouton
|
||||||
BOUTON_ACTIONS_FORMULAIRE.outerHTML = BOUTON_ACTIONS_FORMULAIRE.outerHTML;
|
BOUTON_ACTIONS_FORMULAIRE.outerHTML = BOUTON_ACTIONS_FORMULAIRE.outerHTML;
|
||||||
|
|
@ -686,4 +831,5 @@ document.addEventListener("DOMContentLoaded", (): void => {
|
||||||
initialiseMajContenuPanier();
|
initialiseMajContenuPanier();
|
||||||
initialiseMajFormulairesPanier();
|
initialiseMajFormulairesPanier();
|
||||||
initialiseBoutonActions();
|
initialiseBoutonActions();
|
||||||
|
initialiseElementsCodePromo();
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,15 @@
|
||||||
<div
|
<div
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-index="0"
|
data-index="0"
|
||||||
|
>
|
||||||
|
{{
|
||||||
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll0", "", 903, 1080)
|
||||||
|
}}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div
|
||||||
|
class="storytelling__image"
|
||||||
|
data-index="1"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll1", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll1", "", 903, 1080)
|
||||||
|
|
@ -18,7 +27,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="1"
|
data-index="2"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll2", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll2", "", 903, 1080)
|
||||||
|
|
@ -29,7 +38,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="2"
|
data-index="3"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll3", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll3", "", 903, 1080)
|
||||||
|
|
@ -51,7 +60,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="4"
|
data-index="5"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll5", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll5", "", 903, 1080)
|
||||||
|
|
@ -62,7 +71,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="5"
|
data-index="6"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll6", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll6", "", 903, 1080)
|
||||||
|
|
@ -73,7 +82,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="6"
|
data-index="7"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll7", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll7", "", 903, 1080)
|
||||||
|
|
@ -84,7 +93,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="7"
|
data-index="8"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll8", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll8", "", 903, 1080)
|
||||||
|
|
@ -95,7 +104,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="8"
|
data-index="9"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll9", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll9", "", 903, 1080)
|
||||||
|
|
@ -106,7 +115,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="9"
|
data-index="10"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll10", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll10", "", 903, 1080)
|
||||||
|
|
@ -117,7 +126,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="10"
|
data-index="11"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll11", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll11", "", 903, 1080)
|
||||||
|
|
@ -128,7 +137,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="11"
|
data-index="12"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll12", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll12", "", 903, 1080)
|
||||||
|
|
@ -139,7 +148,7 @@
|
||||||
aria-hidden
|
aria-hidden
|
||||||
class="storytelling__image"
|
class="storytelling__image"
|
||||||
data-cache
|
data-cache
|
||||||
data-index="12"
|
data-index="13"
|
||||||
>
|
>
|
||||||
{{
|
{{
|
||||||
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll13", "", 903, 1080)
|
images.genere_source_img_multi_formats("#{ site.theme.link }/assets/img/storytelling/scroll13", "", 903, 1080)
|
||||||
|
|
|
||||||
|
|
@ -82,21 +82,28 @@
|
||||||
spellcheck="true"
|
spellcheck="true"
|
||||||
></textarea>
|
></textarea>
|
||||||
|
|
||||||
<div class="panneau__instructions-code-promo__code-promo">
|
<div
|
||||||
|
class="panneau__instructions-code-promo__code-promo"
|
||||||
|
{{ code_promo ? "data-code-promo-present" : "" }}
|
||||||
|
id="ensemble-code-promo"
|
||||||
|
>
|
||||||
<input
|
<input
|
||||||
id="code-promo"
|
{{ code_promo ? "disabled" : "" }}
|
||||||
|
id="champ-code-promo"
|
||||||
maxlength="20"
|
maxlength="20"
|
||||||
minlength="3"
|
minlength="3"
|
||||||
name="code-promo"
|
name="code-promo"
|
||||||
placeholder="Discount code or gift card"
|
placeholder="Discount code or gift card"
|
||||||
type="text"
|
type="text"
|
||||||
|
value='{{ code_promo ? code_promo : ""}}'
|
||||||
/>
|
/>
|
||||||
<button
|
<button
|
||||||
class="bouton-blanc-sur-noir"
|
class="bouton-blanc-sur-noir"
|
||||||
for="code-promo"
|
for="code-promo"
|
||||||
|
id="bouton-code-promo"
|
||||||
type="button"
|
type="button"
|
||||||
>
|
>
|
||||||
Apply
|
{{ code_promo ? "Remove" : "Apply" }}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -107,7 +114,16 @@
|
||||||
id="sous-total-produits"
|
id="sous-total-produits"
|
||||||
>
|
>
|
||||||
<p>Subtotal:</p>
|
<p>Subtotal:</p>
|
||||||
<p><strong>{{ sous_total_panier }} €</strong></p>
|
<p><strong>{{ sous_total_panier }}€</strong></p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div
|
||||||
|
class="panneau__sous-totaux__ligne"
|
||||||
|
id="sous-total-reduction"
|
||||||
|
{{ code_promo ? "" : "hidden"}}
|
||||||
|
>
|
||||||
|
<p>Discount:</p>
|
||||||
|
<p><strong>-{{ sous_total_reduction }}€</strong></p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div
|
<div
|
||||||
|
|
@ -123,12 +139,12 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<p class="panneau__sous-totaux__conditions-livraison">
|
<p class="panneau__sous-totaux__conditions-livraison">
|
||||||
Belgium and France: free shipping.<br />
|
Belgium and France: free shipping on orders above 50€.<br />
|
||||||
Worldwide: free shipping on orders above 150 €.
|
Worldwide: free shipping on orders above 150€.
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<footer class="panneau__pied-de-page">
|
<footer class="panneau__pied-de-page">
|
||||||
<p>Total: <span>{{ total_panier }} €</span></p>
|
<p>Total: <span>{{ total_panier }}€</span></p>
|
||||||
</footer>
|
</footer>
|
||||||
</section>
|
</section>
|
||||||
|
|
|
||||||