From 6b854ad9e543c104220b642afecec8ac770c0540 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dicky=20Herlambang=20=28=E8=8A=B1=EF=BC=89?= Date: Sun, 10 Nov 2024 17:42:47 +0700 Subject: [PATCH 1/6] Treewide: Weekly composer and npm updates MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Dicky Herlambang (花) --- composer.lock | 34 +++++----- package-lock.json | 168 +++++++++++++++++++++++----------------------- 2 files changed, 101 insertions(+), 101 deletions(-) diff --git a/composer.lock b/composer.lock index 52a8e9c..799c6cb 100644 --- a/composer.lock +++ b/composer.lock @@ -2134,16 +2134,16 @@ }, { "name": "nesbot/carbon", - "version": "3.8.1", + "version": "3.8.2", "source": { "type": "git", "url": "https://github.com/briannesbitt/Carbon.git", - "reference": "10ac0aa86b8062219ce21e8189123d611ca3ecd9" + "reference": "e1268cdbc486d97ce23fef2c666dc3c6b6de9947" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/10ac0aa86b8062219ce21e8189123d611ca3ecd9", - "reference": "10ac0aa86b8062219ce21e8189123d611ca3ecd9", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/e1268cdbc486d97ce23fef2c666dc3c6b6de9947", + "reference": "e1268cdbc486d97ce23fef2c666dc3c6b6de9947", "shasum": "" }, "require": { @@ -2236,7 +2236,7 @@ "type": "tidelift" } ], - "time": "2024-11-03T16:02:24+00:00" + "time": "2024-11-07T17:46:48+00:00" }, { "name": "nette/schema", @@ -5821,16 +5821,16 @@ "packages-dev": [ { "name": "fakerphp/faker", - "version": "v1.23.1", + "version": "v1.24.0", "source": { "type": "git", "url": "https://github.com/FakerPHP/Faker.git", - "reference": "bfb4fe148adbf78eff521199619b93a52ae3554b" + "reference": "a136842a532bac9ecd8a1c723852b09915d7db50" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/FakerPHP/Faker/zipball/bfb4fe148adbf78eff521199619b93a52ae3554b", - "reference": "bfb4fe148adbf78eff521199619b93a52ae3554b", + "url": "https://api.github.com/repos/FakerPHP/Faker/zipball/a136842a532bac9ecd8a1c723852b09915d7db50", + "reference": "a136842a532bac9ecd8a1c723852b09915d7db50", "shasum": "" }, "require": { @@ -5878,9 +5878,9 @@ ], "support": { "issues": "https://github.com/FakerPHP/Faker/issues", - "source": "https://github.com/FakerPHP/Faker/tree/v1.23.1" + "source": "https://github.com/FakerPHP/Faker/tree/v1.24.0" }, - "time": "2024-01-02T13:46:09+00:00" + "time": "2024-11-07T15:11:20+00:00" }, { "name": "filp/whoops", @@ -6218,16 +6218,16 @@ }, { "name": "myclabs/deep-copy", - "version": "1.12.0", + "version": "1.12.1", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c" + "reference": "123267b2c49fbf30d78a7b2d333f6be754b94845" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", - "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/123267b2c49fbf30d78a7b2d333f6be754b94845", + "reference": "123267b2c49fbf30d78a7b2d333f6be754b94845", "shasum": "" }, "require": { @@ -6266,7 +6266,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.12.0" + "source": "https://github.com/myclabs/DeepCopy/tree/1.12.1" }, "funding": [ { @@ -6274,7 +6274,7 @@ "type": "tidelift" } ], - "time": "2024-06-12T14:39:25+00:00" + "time": "2024-11-08T17:47:46+00:00" }, { "name": "nunomaduro/collision", diff --git a/package-lock.json b/package-lock.json index eb01471..bb4047b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -766,9 +766,9 @@ } }, "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.24.4.tgz", - "integrity": "sha512-jfUJrFct/hTA0XDM5p/htWKoNNTbDLY0KRwEt6pyOA6k2fmk0WVwl65PdUdJZgzGEHWx+49LilkcSaumQRyNQw==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.25.0.tgz", + "integrity": "sha512-CC/ZqFZwlAIbU1wUPisHyV/XRc5RydFrNLtgl3dGYskdwPZdt4HERtKm50a/+DtTlKeCq9IXFEWR+P6blwjqBA==", "cpu": [ "arm" ], @@ -780,9 +780,9 @@ ] }, "node_modules/@rollup/rollup-android-arm64": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.24.4.tgz", - "integrity": "sha512-j4nrEO6nHU1nZUuCfRKoCcvh7PIywQPUCBa2UsootTHvTHIoIu2BzueInGJhhvQO/2FTRdNYpf63xsgEqH9IhA==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.25.0.tgz", + "integrity": "sha512-/Y76tmLGUJqVBXXCfVS8Q8FJqYGhgH4wl4qTA24E9v/IJM0XvJCGQVSW1QZ4J+VURO9h8YCa28sTFacZXwK7Rg==", "cpu": [ "arm64" ], @@ -794,9 +794,9 @@ ] }, "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.24.4.tgz", - "integrity": "sha512-GmU/QgGtBTeraKyldC7cDVVvAJEOr3dFLKneez/n7BvX57UdhOqDsVwzU7UOnYA7AAOt+Xb26lk79PldDHgMIQ==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.25.0.tgz", + "integrity": "sha512-YVT6L3UrKTlC0FpCZd0MGA7NVdp7YNaEqkENbWQ7AOVOqd/7VzyHpgIpc1mIaxRAo1ZsJRH45fq8j4N63I/vvg==", "cpu": [ "arm64" ], @@ -808,9 +808,9 @@ ] }, "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.24.4.tgz", - "integrity": "sha512-N6oDBiZCBKlwYcsEPXGDE4g9RoxZLK6vT98M8111cW7VsVJFpNEqvJeIPfsCzbf0XEakPslh72X0gnlMi4Ddgg==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.25.0.tgz", + "integrity": "sha512-ZRL+gexs3+ZmmWmGKEU43Bdn67kWnMeWXLFhcVv5Un8FQcx38yulHBA7XR2+KQdYIOtD0yZDWBCudmfj6lQJoA==", "cpu": [ "x64" ], @@ -822,9 +822,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-arm64": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.24.4.tgz", - "integrity": "sha512-py5oNShCCjCyjWXCZNrRGRpjWsF0ic8f4ieBNra5buQz0O/U6mMXCpC1LvrHuhJsNPgRt36tSYMidGzZiJF6mw==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.25.0.tgz", + "integrity": "sha512-xpEIXhiP27EAylEpreCozozsxWQ2TJbOLSivGfXhU4G1TBVEYtUPi2pOZBnvGXHyOdLAUUhPnJzH3ah5cqF01g==", "cpu": [ "arm64" ], @@ -836,9 +836,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-x64": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.24.4.tgz", - "integrity": "sha512-L7VVVW9FCnTTp4i7KrmHeDsDvjB4++KOBENYtNYAiYl96jeBThFfhP6HVxL74v4SiZEVDH/1ILscR5U9S4ms4g==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.25.0.tgz", + "integrity": "sha512-sC5FsmZGlJv5dOcURrsnIK7ngc3Kirnx3as2XU9uER+zjfyqIjdcMVgzy4cOawhsssqzoAX19qmxgJ8a14Qrqw==", "cpu": [ "x64" ], @@ -850,9 +850,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.24.4.tgz", - "integrity": "sha512-10ICosOwYChROdQoQo589N5idQIisxjaFE/PAnX2i0Zr84mY0k9zul1ArH0rnJ/fpgiqfu13TFZR5A5YJLOYZA==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.25.0.tgz", + "integrity": "sha512-uD/dbLSs1BEPzg564TpRAQ/YvTnCds2XxyOndAO8nJhaQcqQGFgv/DAVko/ZHap3boCvxnzYMa3mTkV/B/3SWA==", "cpu": [ "arm" ], @@ -864,9 +864,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.24.4.tgz", - "integrity": "sha512-ySAfWs69LYC7QhRDZNKqNhz2UKN8LDfbKSMAEtoEI0jitwfAG2iZwVqGACJT+kfYvvz3/JgsLlcBP+WWoKCLcw==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.25.0.tgz", + "integrity": "sha512-ZVt/XkrDlQWegDWrwyC3l0OfAF7yeJUF4fq5RMS07YM72BlSfn2fQQ6lPyBNjt+YbczMguPiJoCfaQC2dnflpQ==", "cpu": [ "arm" ], @@ -878,9 +878,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.24.4.tgz", - "integrity": "sha512-uHYJ0HNOI6pGEeZ/5mgm5arNVTI0nLlmrbdph+pGXpC9tFHFDQmDMOEqkmUObRfosJqpU8RliYoGz06qSdtcjg==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.25.0.tgz", + "integrity": "sha512-qboZ+T0gHAW2kkSDPHxu7quaFaaBlynODXpBVnPxUgvWYaE84xgCKAPEYE+fSMd3Zv5PyFZR+L0tCdYCMAtG0A==", "cpu": [ "arm64" ], @@ -892,9 +892,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.24.4.tgz", - "integrity": "sha512-38yiWLemQf7aLHDgTg85fh3hW9stJ0Muk7+s6tIkSUOMmi4Xbv5pH/5Bofnsb6spIwD5FJiR+jg71f0CH5OzoA==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.25.0.tgz", + "integrity": "sha512-ndWTSEmAaKr88dBuogGH2NZaxe7u2rDoArsejNslugHZ+r44NfWiwjzizVS1nUOHo+n1Z6qV3X60rqE/HlISgw==", "cpu": [ "arm64" ], @@ -906,9 +906,9 @@ ] }, "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.24.4.tgz", - "integrity": "sha512-q73XUPnkwt9ZNF2xRS4fvneSuaHw2BXuV5rI4cw0fWYVIWIBeDZX7c7FWhFQPNTnE24172K30I+dViWRVD9TwA==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.25.0.tgz", + "integrity": "sha512-BVSQvVa2v5hKwJSy6X7W1fjDex6yZnNKy3Kx1JGimccHft6HV0THTwNtC2zawtNXKUu+S5CjXslilYdKBAadzA==", "cpu": [ "ppc64" ], @@ -920,9 +920,9 @@ ] }, "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.24.4.tgz", - "integrity": "sha512-Aie/TbmQi6UXokJqDZdmTJuZBCU3QBDA8oTKRGtd4ABi/nHgXICulfg1KI6n9/koDsiDbvHAiQO3YAUNa/7BCw==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.25.0.tgz", + "integrity": "sha512-G4hTREQrIdeV0PE2JruzI+vXdRnaK1pg64hemHq2v5fhv8C7WjVaeXc9P5i4Q5UC06d/L+zA0mszYIKl+wY8oA==", "cpu": [ "riscv64" ], @@ -934,9 +934,9 @@ ] }, "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.24.4.tgz", - "integrity": "sha512-P8MPErVO/y8ohWSP9JY7lLQ8+YMHfTI4bAdtCi3pC2hTeqFJco2jYspzOzTUB8hwUWIIu1xwOrJE11nP+0JFAQ==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.25.0.tgz", + "integrity": "sha512-9T/w0kQ+upxdkFL9zPVB6zy9vWW1deA3g8IauJxojN4bnz5FwSsUAD034KpXIVX5j5p/rn6XqumBMxfRkcHapQ==", "cpu": [ "s390x" ], @@ -948,9 +948,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.24.4.tgz", - "integrity": "sha512-K03TljaaoPK5FOyNMZAAEmhlyO49LaE4qCsr0lYHUKyb6QacTNF9pnfPpXnFlFD3TXuFbFbz7tJ51FujUXkXYA==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.25.0.tgz", + "integrity": "sha512-ThcnU0EcMDn+J4B9LD++OgBYxZusuA7iemIIiz5yzEcFg04VZFzdFjuwPdlURmYPZw+fgVrFzj4CA64jSTG4Ig==", "cpu": [ "x64" ], @@ -962,9 +962,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.24.4.tgz", - "integrity": "sha512-VJYl4xSl/wqG2D5xTYncVWW+26ICV4wubwN9Gs5NrqhJtayikwCXzPL8GDsLnaLU3WwhQ8W02IinYSFJfyo34Q==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.25.0.tgz", + "integrity": "sha512-zx71aY2oQxGxAT1JShfhNG79PnjYhMC6voAjzpu/xmMjDnKNf6Nl/xv7YaB/9SIa9jDYf8RBPWEnjcdlhlv1rQ==", "cpu": [ "x64" ], @@ -976,9 +976,9 @@ ] }, "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.24.4.tgz", - "integrity": "sha512-ku2GvtPwQfCqoPFIJCqZ8o7bJcj+Y54cZSr43hHca6jLwAiCbZdBUOrqE6y29QFajNAzzpIOwsckaTFmN6/8TA==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.25.0.tgz", + "integrity": "sha512-JT8tcjNocMs4CylWY/CxVLnv8e1lE7ff1fi6kbGocWwxDq9pj30IJ28Peb+Y8yiPNSF28oad42ApJB8oUkwGww==", "cpu": [ "arm64" ], @@ -990,9 +990,9 @@ ] }, "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.24.4.tgz", - "integrity": "sha512-V3nCe+eTt/W6UYNr/wGvO1fLpHUrnlirlypZfKCT1fG6hWfqhPgQV/K/mRBXBpxc0eKLIF18pIOFVPh0mqHjlg==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.25.0.tgz", + "integrity": "sha512-dRLjLsO3dNOfSN6tjyVlG+Msm4IiZnGkuZ7G5NmpzwF9oOc582FZG05+UdfTbz5Jd4buK/wMb6UeHFhG18+OEg==", "cpu": [ "ia32" ], @@ -1004,9 +1004,9 @@ ] }, "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.24.4.tgz", - "integrity": "sha512-LTw1Dfd0mBIEqUVCxbvTE/LLo+9ZxVC9k99v1v4ahg9Aak6FpqOfNu5kRkeTAn0wphoC4JU7No1/rL+bBCEwhg==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.25.0.tgz", + "integrity": "sha512-/RqrIFtLB926frMhZD0a5oDa4eFIbyNEwLLloMTEjmqfwZWXywwVVOVmwTsuyhC9HKkVEZcOOi+KV4U9wmOdlg==", "cpu": [ "x64" ], @@ -1253,9 +1253,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001678", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001678.tgz", - "integrity": "sha512-RR+4U/05gNtps58PEBDZcPWTgEO2MBeoPZ96aQcjmfkBWRIDfN451fW2qyDA9/+HohLLIL5GqiMwA+IB1pWarw==", + "version": "1.0.30001679", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001679.tgz", + "integrity": "sha512-j2YqID/YwpLnKzCmBOS4tlZdWprXm3ZmQLBH9ZBXFOhoxLA46fwyBvx6toCBWBmnuwUY/qB3kEU6gFx8qgCroA==", "dev": true, "funding": [ { @@ -1355,9 +1355,9 @@ } }, "node_modules/cross-spawn": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", - "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "version": "7.0.5", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.5.tgz", + "integrity": "sha512-ZVJrKKYunU38/76t0RMOulHOnUcbU9GbpWKAOZ0mhjr7CX6FVrH+4FrAapSOekrgFQ3f/8gwMEuIft0aKq6Hug==", "dev": true, "license": "MIT", "dependencies": { @@ -1458,9 +1458,9 @@ "license": "MIT" }, "node_modules/electron-to-chromium": { - "version": "1.5.52", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.52.tgz", - "integrity": "sha512-xtoijJTZ+qeucLBDNztDOuQBE1ksqjvNjvqFoST3nGC7fSpqJ+X6BdTBaY5BHG+IhWWmpc6b/KfpeuEDupEPOQ==", + "version": "1.5.55", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.55.tgz", + "integrity": "sha512-6maZ2ASDOTBtjt9FhqYPRnbvKU5tjG0IN9SztUOWYw2AzNDNpKJYLJmlK0/En4Hs/aiWnB+JZ+gW19PIGszgKg==", "dev": true, "license": "ISC" }, @@ -2422,9 +2422,9 @@ } }, "node_modules/rollup": { - "version": "4.24.4", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.24.4.tgz", - "integrity": "sha512-vGorVWIsWfX3xbcyAS+I047kFKapHYivmkaT63Smj77XwvLSJos6M1xGqZnBPFQFBRZDOcG1QnYEIxAvTr/HjA==", + "version": "4.25.0", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.25.0.tgz", + "integrity": "sha512-uVbClXmR6wvx5R1M3Od4utyLUxrmOcEm3pAtMphn73Apq19PDtHpgZoEvqH2YnnaNUuvKmg2DgRd2Sqv+odyqg==", "devOptional": true, "license": "MIT", "dependencies": { @@ -2438,24 +2438,24 @@ "npm": ">=8.0.0" }, "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.24.4", - "@rollup/rollup-android-arm64": "4.24.4", - "@rollup/rollup-darwin-arm64": "4.24.4", - "@rollup/rollup-darwin-x64": "4.24.4", - "@rollup/rollup-freebsd-arm64": "4.24.4", - "@rollup/rollup-freebsd-x64": "4.24.4", - "@rollup/rollup-linux-arm-gnueabihf": "4.24.4", - "@rollup/rollup-linux-arm-musleabihf": "4.24.4", - "@rollup/rollup-linux-arm64-gnu": "4.24.4", - "@rollup/rollup-linux-arm64-musl": "4.24.4", - "@rollup/rollup-linux-powerpc64le-gnu": "4.24.4", - "@rollup/rollup-linux-riscv64-gnu": "4.24.4", - "@rollup/rollup-linux-s390x-gnu": "4.24.4", - "@rollup/rollup-linux-x64-gnu": "4.24.4", - "@rollup/rollup-linux-x64-musl": "4.24.4", - "@rollup/rollup-win32-arm64-msvc": "4.24.4", - "@rollup/rollup-win32-ia32-msvc": "4.24.4", - "@rollup/rollup-win32-x64-msvc": "4.24.4", + "@rollup/rollup-android-arm-eabi": "4.25.0", + "@rollup/rollup-android-arm64": "4.25.0", + "@rollup/rollup-darwin-arm64": "4.25.0", + "@rollup/rollup-darwin-x64": "4.25.0", + "@rollup/rollup-freebsd-arm64": "4.25.0", + "@rollup/rollup-freebsd-x64": "4.25.0", + "@rollup/rollup-linux-arm-gnueabihf": "4.25.0", + "@rollup/rollup-linux-arm-musleabihf": "4.25.0", + "@rollup/rollup-linux-arm64-gnu": "4.25.0", + "@rollup/rollup-linux-arm64-musl": "4.25.0", + "@rollup/rollup-linux-powerpc64le-gnu": "4.25.0", + "@rollup/rollup-linux-riscv64-gnu": "4.25.0", + "@rollup/rollup-linux-s390x-gnu": "4.25.0", + "@rollup/rollup-linux-x64-gnu": "4.25.0", + "@rollup/rollup-linux-x64-musl": "4.25.0", + "@rollup/rollup-win32-arm64-msvc": "4.25.0", + "@rollup/rollup-win32-ia32-msvc": "4.25.0", + "@rollup/rollup-win32-x64-msvc": "4.25.0", "fsevents": "~2.3.2" } }, From e45a339992e4c67d1044b1156111305d53fcd179 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dicky=20Herlambang=20=28=E8=8A=B1=EF=BC=89?= Date: Mon, 11 Nov 2024 07:34:43 +0700 Subject: [PATCH 2/6] Helpers: Check to all related column while generate UUID MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Dicky Herlambang (花) --- app/Helpers/AppHelper.php | 53 ++++++++++++++++++----------------- app/Models/cnvModel.php | 31 ++++++++++++++++++++ app/Models/compressModel.php | 31 ++++++++++++++++++++ app/Models/htmlModel.php | 30 ++++++++++++++++++++ app/Models/mergeModel.php | 29 +++++++++++++++++++ app/Models/splitModel.php | 36 ++++++++++++++++++++++++ app/Models/watermarkModel.php | 40 ++++++++++++++++++++++++++ 7 files changed, 225 insertions(+), 25 deletions(-) create mode 100644 app/Models/cnvModel.php create mode 100644 app/Models/compressModel.php create mode 100644 app/Models/htmlModel.php create mode 100644 app/Models/mergeModel.php create mode 100644 app/Models/splitModel.php create mode 100644 app/Models/watermarkModel.php diff --git a/app/Helpers/AppHelper.php b/app/Helpers/AppHelper.php index 84107a0..65387b5 100644 --- a/app/Helpers/AppHelper.php +++ b/app/Helpers/AppHelper.php @@ -2,8 +2,14 @@ namespace App\Helpers; use App\Models\appLogModel; +use App\Models\jobLogModel; use App\Models\notifyLogModel; -use Carbon\Carbon; +use App\Models\compressModel; +use App\Models\cnvModel; +use App\Models\htmlModel; +use App\Models\mergeModel; +use App\Models\splitModel; +use App\Models\watermarkModel; use Illuminate\Support\Facades\Http; use Illuminate\Support\Facades\Log; use Ramsey\Uuid\Uuid; @@ -29,32 +35,29 @@ function getCurrentTimeZone() { return $currentDateTime; } - function generateSingleUniqueUuid($customModel, $customColumn) { - $startProc = Carbon::now()->format('Y-m-d H:i:s'); - $uniqueID = Uuid::uuid4(); - // do { - // $uniqueID = Uuid::uuid4(); - // } while ( - // $customModel::where($customColumn, $uniqueID)->exists() - // ); - $end = Carbon::now(); - $duration = $end->diffInSeconds(Carbon::parse($startProc)); - Log::Info('New single unique UUID has been generated with response time: '.$duration.' seconds'); - return $uniqueID->toString(); - } - function generateUniqueUuid($customModel, $customColumn) { - $startProc = Carbon::now()->format('Y-m-d H:i:s'); $uniqueID = Uuid::uuid4(); - // do { - // $uniqueID = Uuid::uuid4(); - // } while ( - // appLogModel::where($customColumn, $uniqueID)->exists() || - // $customModel::where($customColumn, $uniqueID)->exists() - // ); - $end = Carbon::now(); - $duration = $end->diffInSeconds(Carbon::parse($startProc)); - Log::Info('New unique UUID has been generated with response time: '.$duration.' seconds'); + // if ($customColumn !== 'processId') { + // do { + // $uniqueID = Uuid::uuid4(); + // } while ( + // $customModel::where($customColumn, $uniqueID)->exists() + // ); + // } else { + // do { + // $uniqueID = Uuid::uuid4(); + // } while ( + // appLogModel::where($customColumn, $uniqueID)->exists() || + // jobLogModel::where($customColumn, $uniqueID)->exists() || + // notifyLogModel::where($customColumn, $uniqueID)->exists() || + // compressModel::where($customColumn, $uniqueID)->exists() || + // cnvModel::where($customColumn, $uniqueID)->exists() || + // htmlModel::where($customColumn, $uniqueID)->exists() || + // mergeModel::where($customColumn, $uniqueID)->exists() || + // splitModel::where($customColumn, $uniqueID)->exists() || + // watermarkModel::where($customColumn, $uniqueID)->exists() + // ); + // } return $uniqueID->toString(); } diff --git a/app/Models/cnvModel.php b/app/Models/cnvModel.php new file mode 100644 index 0000000..437470c --- /dev/null +++ b/app/Models/cnvModel.php @@ -0,0 +1,31 @@ + Date: Mon, 11 Nov 2024 07:35:10 +0700 Subject: [PATCH 3/6] Exceptions: Handler: Use more proper function to generate UUID MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Dicky Herlambang (花) --- app/Exceptions/Handler.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.php index 4cd851f..641417e 100644 --- a/app/Exceptions/Handler.php +++ b/app/Exceptions/Handler.php @@ -41,8 +41,8 @@ public function register(): void public function render($request, Throwable $exception) { - $uuid = AppHelper::Instance()->generateSingleUniqueUuid(appLogModel::class, 'processId'); - $Muuid = AppHelper::Instance()->generateSingleUniqueUuid(appLogModel::class, 'groupId'); + $uuid = AppHelper::Instance()->generateUniqueUuid(appLogModel::class, 'processId'); + $Muuid = AppHelper::Instance()->generateUniqueUuid(appLogModel::class, 'groupId'); appLogModel::create([ 'processId' => $uuid, From ef1ded246da489845cb19c137d2526ca23ed1d89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dicky=20Herlambang=20=28=E8=8A=B1=EF=BC=89?= Date: Mon, 11 Nov 2024 07:35:42 +0700 Subject: [PATCH 4/6] Resources: kao-logic: Minor updates MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Drop hash commit validation for versioningValidate - Fix unproper error message from dropzoneJS Signed-off-by: Dicky Herlambang (花) --- resources/js/getGitCommitHash.js | 13 ----- resources/js/kao-logic.js | 94 +++++++++++++------------------- vite.config.js | 4 -- 3 files changed, 38 insertions(+), 73 deletions(-) delete mode 100644 resources/js/getGitCommitHash.js diff --git a/resources/js/getGitCommitHash.js b/resources/js/getGitCommitHash.js deleted file mode 100644 index 0e53827..0000000 --- a/resources/js/getGitCommitHash.js +++ /dev/null @@ -1,13 +0,0 @@ -import { execSync } from 'child_process'; - -function getGitCommitHash() { - try { - const hash = execSync('git rev-parse --short HEAD').toString().trim(); - return hash; - } catch (error) { - console.error('Error getting Git commit hash:', error); - return null; - } -} - -export default getGitCommitHash; diff --git a/resources/js/kao-logic.js b/resources/js/kao-logic.js index 7f6b94a..90db9d1 100644 --- a/resources/js/kao-logic.js +++ b/resources/js/kao-logic.js @@ -29,10 +29,9 @@ const options = { const adobeClientID = "STATIC_CLIENT_ID"; const appMajorVer = 3; const appMinorVer = 3; -const appPatchVer = 8; +const appPatchVer = 9; const apiUrl = "http://192.168.0.2"; const bearerToken = "STATIC_BEARER"; -const commitHash = gitHash; const errModal = new Modal($errModal, options); const googleViewerUrl = "https://docs.google.com/viewerng/viewer?url="; const loadingModal = new Modal($loadingModal, options); @@ -490,27 +489,22 @@ if (uploadDropzone) { file.previewElement.querySelector(".dz-error-message"); let newErrMessage = "Internal server error"; - if (dzErrorMessage) { - if ( - dropzoneErrMessage === "[object Object]" && - xhr.readyState === XMLHttpRequest.DONE - ) { - try { - const xhrResponse = JSON.parse(xhr.responseText); - newErrMessage = - xhrResponse.errors || - "There was an unexpected error"; - } catch (error) { - newErrMessage = "Failed to parse server response"; - } - } else { + if (xhr.readyState === XMLHttpRequest.DONE) { + try { + const xhrResponse = JSON.parse(xhr.responseText); newErrMessage = - dropzoneErrMessage || "Server was not ready"; + xhrResponse.errors || + "There was an unexpected error"; + } catch (error) { + newErrMessage = "Failed to parse server response"; } - - dzErrorMessage.textContent = newErrMessage; + } else { + newErrMessage = + dropzoneErrMessage || "Server was not ready"; } + dzErrorMessage.textContent = newErrMessage; + errMessage.innerText = `Failed to upload ${file.name}`; errSubMessage.innerText = ""; errListTitleMessage.innerText = "Error message"; @@ -809,27 +803,22 @@ if (uploadDropzoneAlt) { file.previewElement.querySelector(".dz-error-message"); let newErrMessage = "Internal server error"; - if (dzErrorMessage) { - if ( - dropzoneErrMessage === "[object Object]" && - xhr.readyState === XMLHttpRequest.DONE - ) { - try { - const xhrResponse = JSON.parse(xhr.responseText); - newErrMessage = - xhrResponse.errors || - "There was an unexpected error"; - } catch (error) { - newErrMessage = "Failed to parse server response"; - } - } else { + if (xhr.readyState === XMLHttpRequest.DONE) { + try { + const xhrResponse = JSON.parse(xhr.responseText); newErrMessage = - dropzoneErrMessage || "Server was not ready"; + xhrResponse.errors || + "There was an unexpected error"; + } catch (error) { + newErrMessage = "Failed to parse server response"; } - - dzErrorMessage.textContent = newErrMessage; + } else { + newErrMessage = + dropzoneErrMessage || "Server was not ready"; } + dzErrorMessage.textContent = newErrMessage; + errMessage.innerText = `Failed to upload ${file.name}`; errSubMessage.innerText = ""; errListTitleMessage.innerText = "Error message"; @@ -1069,7 +1058,7 @@ if (uploadDropzoneSingle) { xhrTotalUploads = xhrTotalUploads - 1; } - fetch(`${apiUrl}/api/v1/file/upload`, { + fetch(`${apiUrl}/api/v1/file/remove`, { method: "POST", headers: { "Content-Type": "application/json", @@ -1111,28 +1100,22 @@ if (uploadDropzoneSingle) { const dzErrorMessage = file.previewElement.querySelector(".dz-error-message"); let newErrMessage = "Internal server error"; - - if (dzErrorMessage) { - if ( - dropzoneErrMessage === "[object Object]" && - xhr.readyState === XMLHttpRequest.DONE - ) { - try { - const xhrResponse = JSON.parse(xhr.responseText); - newErrMessage = - xhrResponse.errors || - "There was an unexpected error"; - } catch (error) { - newErrMessage = "Failed to parse server response"; - } - } else { + if (xhr.readyState === XMLHttpRequest.DONE) { + try { + const xhrResponse = JSON.parse(xhr.responseText); newErrMessage = - dropzoneErrMessage || "Server was not ready"; + xhrResponse.errors || + "There was an unexpected error"; + } catch (error) { + newErrMessage = "Failed to parse server response"; } - - dzErrorMessage.textContent = newErrMessage; + } else { + newErrMessage = + dropzoneErrMessage || "Server was not ready"; } + dzErrorMessage.textContent = newErrMessage; + errMessage.innerText = `Failed to upload ${file.name}`; errSubMessage.innerText = ""; errListTitleMessage.innerText = "Error message"; @@ -3175,7 +3158,6 @@ function validateVersion() { formData.append("appMajorVersion", appMajorVer); formData.append("appMinorVersion", appMinorVer); formData.append("appPatchVersion", appPatchVer); - formData.append("appGitVersion", commitHash); formData.append("appServicesReferrer", "FE"); xhr.open("POST", `${apiUrl}/api/v1/version/check`, true); diff --git a/vite.config.js b/vite.config.js index 1102a8f..9bef2d9 100644 --- a/vite.config.js +++ b/vite.config.js @@ -1,11 +1,7 @@ import { defineConfig } from "vite"; import laravel from "laravel-vite-plugin"; -import getGitCommitHash from "./resources/js/getGitCommitHash"; export default defineConfig({ - define: { - gitHash: JSON.stringify(getGitCommitHash()), - }, plugins: [ laravel({ input: [ From 01d26452df1ae9f7967151b448b21f1e3a39be4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dicky=20Herlambang=20=28=E8=8A=B1=EF=BC=89?= Date: Mon, 11 Nov 2024 07:39:59 +0700 Subject: [PATCH 5/6] Treewide: Compose and NPM weekly updates MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Dicky Herlambang (花) --- package-lock.json | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/package-lock.json b/package-lock.json index bb4047b..a08e70d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1253,9 +1253,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001679", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001679.tgz", - "integrity": "sha512-j2YqID/YwpLnKzCmBOS4tlZdWprXm3ZmQLBH9ZBXFOhoxLA46fwyBvx6toCBWBmnuwUY/qB3kEU6gFx8qgCroA==", + "version": "1.0.30001680", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001680.tgz", + "integrity": "sha512-rPQy70G6AGUMnbwS1z6Xg+RkHYPAi18ihs47GH0jcxIG7wArmPgY3XbS2sRdBbxJljp3thdT8BIqv9ccCypiPA==", "dev": true, "funding": [ { @@ -2167,9 +2167,9 @@ } }, "node_modules/postcss": { - "version": "8.4.47", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.47.tgz", - "integrity": "sha512-56rxCq7G/XfB4EkXq9Egn5GCqugWvDFjafDOThIdMBsI15iqPqR5r15TfSr1YPYeEI19YeaXMCbY6u88Y76GLQ==", + "version": "8.4.48", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.48.tgz", + "integrity": "sha512-GCRK8F6+Dl7xYniR5a4FYbpBzU8XnZVeowqsQFYdcXuSbChgiks7qybSkbvnaeqv0G0B+dd9/jJgH8kkLDQeEA==", "dev": true, "funding": [ { @@ -2188,7 +2188,7 @@ "license": "MIT", "dependencies": { "nanoid": "^3.3.7", - "picocolors": "^1.1.0", + "picocolors": "^1.1.1", "source-map-js": "^1.2.1" }, "engines": { From 05a0b80a7999597e3c7bbc9bfcd4dd68881d0818 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dicky=20Herlambang=20=28=E8=8A=B1=EF=BC=89?= Date: Mon, 11 Nov 2024 07:41:51 +0700 Subject: [PATCH 6/6] VITE: Update static assets MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Dicky Herlambang (花) --- .../assets/{kao-logic-DS2YxX1w.js => kao-logic-6pgvh_dy.js} | 6 +++--- public/build/manifest.json | 2 +- resources/views/layouts/alternate-layout.blade.php | 2 +- resources/views/layouts/main-layout.blade.php | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) rename public/build/assets/{kao-logic-DS2YxX1w.js => kao-logic-6pgvh_dy.js} (64%) diff --git a/public/build/assets/kao-logic-DS2YxX1w.js b/public/build/assets/kao-logic-6pgvh_dy.js similarity index 64% rename from public/build/assets/kao-logic-DS2YxX1w.js rename to public/build/assets/kao-logic-6pgvh_dy.js index 5f23f24..1fb63cf 100644 --- a/public/build/assets/kao-logic-DS2YxX1w.js +++ b/public/build/assets/kao-logic-6pgvh_dy.js @@ -21,8 +21,8 @@ import{M as X}from"./index-OZjHP72d.js";var ee=de;function de(){var s=[].slice.c `;let ye={url:null,method:"post",withCredentials:!1,timeout:null,parallelUploads:2,uploadMultiple:!1,chunking:!1,forceChunking:!1,chunkSize:2097152,parallelChunkUploads:!1,retryChunks:!1,retryChunksLimit:3,maxFilesize:256,paramName:"file",createImageThumbnails:!0,maxThumbnailFilesize:10,thumbnailWidth:120,thumbnailHeight:120,thumbnailMethod:"crop",resizeWidth:null,resizeHeight:null,resizeMimeType:null,resizeQuality:.8,resizeMethod:"contain",filesizeBase:1e3,maxFiles:null,headers:null,defaultHeaders:!0,clickable:!0,ignoreHiddenFiles:!0,acceptedFiles:null,acceptedMimeTypes:null,autoProcessQueue:!0,autoQueue:!0,addRemoveLinks:!1,previewsContainer:null,disablePreviews:!1,hiddenInputContainer:"body",capture:null,renameFilename:null,renameFile:null,forceFallback:!1,dictDefaultMessage:"Drop files here to upload",dictFallbackMessage:"Your browser does not support drag'n'drop file uploads.",dictFallbackText:"Please use the fallback form below to upload your files like in the olden days.",dictFileTooBig:"File is too big ({{filesize}}MiB). Max filesize: {{maxFilesize}}MiB.",dictInvalidFileType:"You can't upload files of this type.",dictResponseError:"Server responded with {{statusCode}} code.",dictCancelUpload:"Cancel upload",dictUploadCanceled:"Upload canceled.",dictCancelUploadConfirmation:"Are you sure you want to cancel this upload?",dictRemoveFile:"Remove file",dictRemoveFileConfirmation:null,dictMaxFilesExceeded:"You can not upload any more files.",dictFileSizeUnits:{tb:"TB",gb:"GB",mb:"MB",kb:"KB",b:"b"},init(){},params(s,e,n){if(n)return{dzuuid:n.file.upload.uuid,dzchunkindex:n.index,dztotalfilesize:n.file.size,dzchunksize:this.options.chunkSize,dztotalchunkcount:n.file.upload.totalChunkCount,dzchunkbyteoffset:n.index*this.options.chunkSize}},accept(s,e){return e()},chunksUploaded:function(s,e){e()},binaryBody:!1,fallback(){let s;this.element.className=`${this.element.className} dz-browser-not-supported`;for(let n of this.element.getElementsByTagName("div"))if(/(^| )dz-message($| )/.test(n.className)){s=n,n.className="dz-message";break}s||(s=m.createElement('
'),this.element.appendChild(s));let e=s.getElementsByTagName("span")[0];return e&&(e.textContent!=null?e.textContent=this.options.dictFallbackMessage:e.innerText!=null&&(e.innerText=this.options.dictFallbackMessage)),this.element.appendChild(this.getFallbackForm())},resize(s,e,n,t){let i={srcX:0,srcY:0,srcWidth:s.width,srcHeight:s.height},r=s.width/s.height;e==null&&n==null?(e=i.srcWidth,n=i.srcHeight):e==null?e=n*r:n==null&&(n=e/r),e=Math.min(e,i.srcWidth),n=Math.min(n,i.srcHeight);let l=e/n;if(i.srcWidth>e||i.srcHeight>n)if(t==="crop")r>l?(i.srcHeight=s.height,i.srcWidth=i.srcHeight*l):(i.srcWidth=s.width,i.srcHeight=i.srcWidth/l);else if(t==="contain")r>l?n=e/r:e=n*r;else throw new Error(`Unknown resizeMethod '${t}'`);return i.srcX=(s.width-i.srcWidth)/2,i.srcY=(s.height-i.srcHeight)/2,i.trgWidth=e,i.trgHeight=n,i},transformFile(s,e){return(this.options.resizeWidth||this.options.resizeHeight)&&s.type.match(/image.*/)?this.resizeImage(s,this.options.resizeWidth,this.options.resizeHeight,this.options.resizeMethod,e):e(s)},previewTemplate:ve(ue),drop(s){return this.element.classList.remove("dz-drag-hover")},dragstart(s){},dragend(s){return this.element.classList.remove("dz-drag-hover")},dragenter(s){return this.element.classList.add("dz-drag-hover")},dragover(s){return this.element.classList.add("dz-drag-hover")},dragleave(s){return this.element.classList.remove("dz-drag-hover")},paste(s){},reset(){return this.element.classList.remove("dz-started")},addedfile(s){if(this.element===this.previewsContainer&&this.element.classList.add("dz-started"),this.previewsContainer&&!this.options.disablePreviews){s.previewElement=m.createElement(this.options.previewTemplate.trim()),s.previewTemplate=s.previewElement,this.previewsContainer.appendChild(s.previewElement);for(var e of s.previewElement.querySelectorAll("[data-dz-name]"))e.textContent=s.name;for(e of s.previewElement.querySelectorAll("[data-dz-size]"))e.innerHTML=this.filesize(s.size);this.options.addRemoveLinks&&(s._removeLink=m.createElement(`${this.options.dictRemoveFile}`),s.previewElement.appendChild(s._removeLink));let n=t=>(t.preventDefault(),t.stopPropagation(),s.status===m.UPLOADING?m.confirm(this.options.dictCancelUploadConfirmation,()=>this.removeFile(s)):this.options.dictRemoveFileConfirmation?m.confirm(this.options.dictRemoveFileConfirmation,()=>this.removeFile(s)):this.removeFile(s));for(let t of s.previewElement.querySelectorAll("[data-dz-remove]"))t.addEventListener("click",n)}},removedfile(s){return s.previewElement!=null&&s.previewElement.parentNode!=null&&s.previewElement.parentNode.removeChild(s.previewElement),this._updateMaxFilesReachedClass()},thumbnail(s,e){if(s.previewElement){s.previewElement.classList.remove("dz-file-preview");for(let n of s.previewElement.querySelectorAll("[data-dz-thumbnail]"))n.alt=s.name,n.src=e;return setTimeout(()=>s.previewElement.classList.add("dz-image-preview"),1)}},error(s,e){if(s.previewElement){s.previewElement.classList.add("dz-error"),typeof e!="string"&&e.error&&(e=e.error);for(let n of s.previewElement.querySelectorAll("[data-dz-errormessage]"))n.textContent=e}},errormultiple(){},processing(s){if(s.previewElement&&(s.previewElement.classList.add("dz-processing"),s._removeLink))return s._removeLink.innerHTML=this.options.dictCancelUpload},processingmultiple(){},uploadprogress(s,e,n){if(s.previewElement)for(let t of s.previewElement.querySelectorAll("[data-dz-uploadprogress]"))t.nodeName==="PROGRESS"?t.value=e:t.style.width=`${e}%`},totaluploadprogress(){},sending(){},sendingmultiple(){},success(s){if(s.previewElement)return s.previewElement.classList.add("dz-success")},successmultiple(){},canceled(s){return this.emit("error",s,this.options.dictUploadCanceled)},canceledmultiple(){},complete(s){if(s._removeLink&&(s._removeLink.innerHTML=this.options.dictRemoveFile),s.previewElement)return s.previewElement.classList.add("dz-complete")},completemultiple(){},maxfilesexceeded(){},maxfilesreached(){},queuecomplete(){},addedfiles(){}};var Ee=ye;class m extends ne{static initClass(){this.prototype.Emitter=ne,this.prototype.events=["drop","dragstart","dragend","dragenter","dragover","dragleave","addedfile","addedfiles","removedfile","thumbnail","error","errormultiple","processing","processingmultiple","uploadprogress","totaluploadprogress","sending","sendingmultiple","success","successmultiple","canceled","canceledmultiple","complete","completemultiple","reset","maxfilesexceeded","maxfilesreached","queuecomplete"],this.prototype._thumbnailQueue=[],this.prototype._processingThumbnail=!1}getAcceptedFiles(){return this.files.filter(e=>e.accepted).map(e=>e)}getRejectedFiles(){return this.files.filter(e=>!e.accepted).map(e=>e)}getFilesWithStatus(e){return this.files.filter(n=>n.status===e).map(n=>n)}getQueuedFiles(){return this.getFilesWithStatus(m.QUEUED)}getUploadingFiles(){return this.getFilesWithStatus(m.UPLOADING)}getAddedFiles(){return this.getFilesWithStatus(m.ADDED)}getActiveFiles(){return this.files.filter(e=>e.status===m.UPLOADING||e.status===m.QUEUED).map(e=>e)}init(){if(this.element.tagName==="form"&&this.element.setAttribute("enctype","multipart/form-data"),this.element.classList.contains("dropzone")&&!this.element.querySelector(".dz-message")&&this.element.appendChild(m.createElement(`
`)),this.clickableElements.length){let t=()=>{this.hiddenFileInput&&this.hiddenFileInput.parentNode.removeChild(this.hiddenFileInput),this.hiddenFileInput=document.createElement("input"),this.hiddenFileInput.setAttribute("type","file"),(this.options.maxFiles===null||this.options.maxFiles>1)&&this.hiddenFileInput.setAttribute("multiple","multiple"),this.hiddenFileInput.className="dz-hidden-input",this.options.acceptedFiles!==null&&this.hiddenFileInput.setAttribute("accept",this.options.acceptedFiles),this.options.capture!==null&&this.hiddenFileInput.setAttribute("capture",this.options.capture),this.hiddenFileInput.setAttribute("tabindex","-1"),this.hiddenFileInput.style.visibility="hidden",this.hiddenFileInput.style.position="absolute",this.hiddenFileInput.style.top="0",this.hiddenFileInput.style.left="0",this.hiddenFileInput.style.height="0",this.hiddenFileInput.style.width="0",m.getElement(this.options.hiddenInputContainer,"hiddenInputContainer").appendChild(this.hiddenFileInput),this.hiddenFileInput.addEventListener("change",()=>{let{files:i}=this.hiddenFileInput;if(i.length)for(let r of i)this.addFile(r);this.emit("addedfiles",i),t()})};t()}this.URL=window.URL!==null?window.URL:window.webkitURL;for(let t of this.events)this.on(t,this.options[t]);this.on("uploadprogress",()=>this.updateTotalUploadProgress()),this.on("removedfile",()=>this.updateTotalUploadProgress()),this.on("canceled",t=>this.emit("complete",t)),this.on("complete",t=>{if(this.getAddedFiles().length===0&&this.getUploadingFiles().length===0&&this.getQueuedFiles().length===0)return setTimeout(()=>this.emit("queuecomplete"),0)});const e=function(t){if(t.dataTransfer.types){for(var i=0;ithis.emit("dragstart",t),dragenter:t=>(n(t),this.emit("dragenter",t)),dragover:t=>{let i;try{i=t.dataTransfer.effectAllowed}catch{}return t.dataTransfer.dropEffect=i==="move"||i==="linkMove"?"move":"copy",n(t),this.emit("dragover",t)},dragleave:t=>this.emit("dragleave",t),drop:t=>(n(t),this.drop(t)),dragend:t=>this.emit("dragend",t)}}],this.clickableElements.forEach(t=>this.listeners.push({element:t,events:{click:i=>((t!==this.element||i.target===this.element||m.elementInside(i.target,this.element.querySelector(".dz-message")))&&this.hiddenFileInput.click(),!0)}})),this.enable(),this.options.init.call(this)}destroy(){return this.disable(),this.removeAllFiles(!0),this.hiddenFileInput!=null&&this.hiddenFileInput.parentNode&&(this.hiddenFileInput.parentNode.removeChild(this.hiddenFileInput),this.hiddenFileInput=null),delete this.element.dropzone,m.instances.splice(m.instances.indexOf(this),1)}updateTotalUploadProgress(){let e,n=0,t=0;if(this.getActiveFiles().length){for(let r of this.getActiveFiles())n+=r.upload.bytesSent,t+=r.upload.total;e=100*n/t}else e=100;return this.emit("totaluploadprogress",e,t,n)}_getParamName(e){return typeof this.options.paramName=="function"?this.options.paramName(e):`${this.options.paramName}${this.options.uploadMultiple?`[${e}]`:""}`}_renameFile(e){return typeof this.options.renameFile!="function"?e.name:this.options.renameFile(e)}getFallbackForm(){let e,n;if(e=this.getExistingFallback())return e;let t='
';this.options.dictFallbackText&&(t+=`

${this.options.dictFallbackText}

`),t+=`
`;let i=m.createElement(t);return this.element.tagName!=="FORM"?(n=m.createElement(`
`),n.appendChild(i)):(this.element.setAttribute("enctype","multipart/form-data"),this.element.setAttribute("method",this.options.method)),n??i}getExistingFallback(){let e=function(t){for(let i of t)if(/(^| )fallback($| )/.test(i.className))return i};for(let t of["div","form"]){var n;if(n=e(this.element.getElementsByTagName(t)))return n}}setupEventListeners(){return this.listeners.map(e=>(()=>{let n=[];for(let t in e.events){let i=e.events[t];n.push(e.element.addEventListener(t,i,!1))}return n})())}removeEventListeners(){return this.listeners.map(e=>(()=>{let n=[];for(let t in e.events){let i=e.events[t];n.push(e.element.removeEventListener(t,i,!1))}return n})())}disable(){return this.clickableElements.forEach(e=>e.classList.remove("dz-clickable")),this.removeEventListeners(),this.disabled=!0,this.files.map(e=>this.cancelUpload(e))}enable(){return delete this.disabled,this.clickableElements.forEach(e=>e.classList.add("dz-clickable")),this.setupEventListeners()}filesize(e){let n=0,t="b";if(e>0){let i=["tb","gb","mb","kb","b"];for(let r=0;r=o){n=e/Math.pow(this.options.filesizeBase,4-r),t=l;break}}n=Math.round(10*n)/10}return`${n} ${this.options.dictFileSizeUnits[t]}`}_updateMaxFilesReachedClass(){return this.options.maxFiles!=null&&this.getAcceptedFiles().length>=this.options.maxFiles?(this.getAcceptedFiles().length===this.options.maxFiles&&this.emit("maxfilesreached",this.files),this.element.classList.add("dz-max-files-reached")):this.element.classList.remove("dz-max-files-reached")}drop(e){if(!e.dataTransfer)return;this.emit("drop",e);let n=[];for(let t=0;tt.items)==null)return;this.emit("paste",e);let{items:n}=e.clipboardData;if(n.length)return this._addFilesFromItems(n)}handleFiles(e){for(let n of e)this.addFile(n)}_addFilesFromItems(e){return(()=>{let n=[];for(let i of e){var t;i.webkitGetAsEntry!=null&&(t=i.webkitGetAsEntry())?t.isFile?n.push(this.addFile(i.getAsFile())):t.isDirectory?n.push(this._addFilesFromDirectory(t,t.name)):n.push(void 0):i.getAsFile!=null&&(i.kind==null||i.kind==="file")?n.push(this.addFile(i.getAsFile())):n.push(void 0)}return n})()}_addFilesFromDirectory(e,n){let t=e.createReader(),i=l=>Be(console,"log",o=>o.log(l));var r=()=>t.readEntries(l=>{if(l.length>0){for(let o of l)o.isFile?o.file(p=>{if(!(this.options.ignoreHiddenFiles&&p.name.substring(0,1)==="."))return p.fullPath=`${n}/${p.name}`,this.addFile(p)}):o.isDirectory&&this._addFilesFromDirectory(o,`${n}/${o.name}`);r()}return null},i);return r()}accept(e,n){this.options.maxFilesize&&e.size>this.options.maxFilesize*1048576?n(this.options.dictFileTooBig.replace("{{filesize}}",Math.round(e.size/1024/10.24)/100).replace("{{maxFilesize}}",this.options.maxFilesize)):m.isValidFile(e,this.options.acceptedFiles)?this.options.maxFiles!=null&&this.getAcceptedFiles().length>=this.options.maxFiles?(n(this.options.dictMaxFilesExceeded.replace("{{maxFiles}}",this.options.maxFiles)),this.emit("maxfilesexceeded",e)):this.options.accept.call(this,e,n):n(this.options.dictInvalidFileType)}addFile(e){e.upload={uuid:m.uuidv4(),progress:0,total:e.size,bytesSent:0,filename:this._renameFile(e)},this.files.push(e),e.status=m.ADDED,this.emit("addedfile",e),this._enqueueThumbnail(e),this.accept(e,n=>{n?(e.accepted=!1,this._errorProcessing([e],n)):(e.accepted=!0,this.options.autoQueue&&this.enqueueFile(e)),this._updateMaxFilesReachedClass()})}enqueueFiles(e){for(let n of e)this.enqueueFile(n);return null}enqueueFile(e){if(e.status===m.ADDED&&e.accepted===!0){if(e.status=m.QUEUED,this.options.autoProcessQueue)return setTimeout(()=>this.processQueue(),0)}else throw new Error("This file can't be queued because it has already been processed or was rejected.")}_enqueueThumbnail(e){if(this.options.createImageThumbnails&&e.type.match(/image.*/)&&e.size<=this.options.maxThumbnailFilesize*1048576)return this._thumbnailQueue.push(e),setTimeout(()=>this._processThumbnailQueue(),0)}_processThumbnailQueue(){if(this._processingThumbnail||this._thumbnailQueue.length===0)return;this._processingThumbnail=!0;let e=this._thumbnailQueue.shift();return this.createThumbnail(e,this.options.thumbnailWidth,this.options.thumbnailHeight,this.options.thumbnailMethod,!0,n=>(this.emit("thumbnail",e,n),this._processingThumbnail=!1,this._processThumbnailQueue()))}removeFile(e){if(e.status===m.UPLOADING&&this.cancelUpload(e),this.files=xe(this.files,e),this.emit("removedfile",e),this.files.length===0)return this.emit("reset")}removeAllFiles(e){e==null&&(e=!1);for(let n of this.files.slice())(n.status!==m.UPLOADING||e)&&this.removeFile(n);return null}resizeImage(e,n,t,i,r){return this.createThumbnail(e,n,t,i,!0,(l,o)=>{if(o==null)return r(e);{let{resizeMimeType:p}=this.options;p==null&&(p=e.type);let g=o.toDataURL(p,this.options.resizeQuality);return(p==="image/jpeg"||p==="image/jpg")&&(g=ce.restore(e.dataURL,g)),r(m.dataURItoBlob(g))}})}createThumbnail(e,n,t,i,r,l){let o=new FileReader;o.onload=()=>{if(e.dataURL=o.result,e.type==="image/svg+xml"){l!=null&&l(o.result);return}this.createThumbnailFromUrl(e,n,t,i,r,l)},o.readAsDataURL(e)}displayExistingFile(e,n,t,i,r=!0){if(this.emit("addedfile",e),this.emit("complete",e),!r)this.emit("thumbnail",e,n),t&&t();else{let l=o=>{this.emit("thumbnail",e,o),t&&t()};e.dataURL=n,this.createThumbnailFromUrl(e,this.options.thumbnailWidth,this.options.thumbnailHeight,this.options.thumbnailMethod,this.options.fixOrientation,l,i)}}createThumbnailFromUrl(e,n,t,i,r,l,o){let p=document.createElement("img");return o&&(p.crossOrigin=o),r=getComputedStyle(document.body).imageOrientation=="from-image"?!1:r,p.onload=()=>{let g=E=>E(1);return typeof EXIF<"u"&&EXIF!==null&&r&&(g=E=>EXIF.getData(p,function(){return E(EXIF.getTag(this,"Orientation"))})),g(E=>{e.width=p.width,e.height=p.height;let x=this.options.resize.call(this,e,n,t,i),T=document.createElement("canvas"),b=T.getContext("2d");switch(T.width=x.trgWidth,T.height=x.trgHeight,E>4&&(T.width=x.trgHeight,T.height=x.trgWidth),E){case 2:b.translate(T.width,0),b.scale(-1,1);break;case 3:b.translate(T.width,T.height),b.rotate(Math.PI);break;case 4:b.translate(0,T.height),b.scale(1,-1);break;case 5:b.rotate(.5*Math.PI),b.scale(1,-1);break;case 6:b.rotate(.5*Math.PI),b.translate(0,-T.width);break;case 7:b.rotate(.5*Math.PI),b.translate(T.height,-T.width),b.scale(-1,1);break;case 8:b.rotate(-.5*Math.PI),b.translate(-T.height,0);break}be(b,p,x.srcX!=null?x.srcX:0,x.srcY!=null?x.srcY:0,x.srcWidth,x.srcHeight,x.trgX!=null?x.trgX:0,x.trgY!=null?x.trgY:0,x.trgWidth,x.trgHeight);let H=T.toDataURL("image/png");if(l!=null)return l(H,T)})},l!=null&&(p.onerror=l),p.src=e.dataURL}processQueue(){let{parallelUploads:e}=this.options,n=this.getUploadingFiles().length,t=n;if(n>=e)return;let i=this.getQueuedFiles();if(i.length>0){if(this.options.uploadMultiple)return this.processFiles(i.slice(0,e-n));for(;tn.xhr===e).map(n=>n)}cancelUpload(e){if(e.status===m.UPLOADING){let n=this._getFilesWithXhr(e.xhr);for(let t of n)t.status=m.CANCELED;typeof e.xhr<"u"&&e.xhr.abort();for(let t of n)this.emit("canceled",t);this.options.uploadMultiple&&this.emit("canceledmultiple",n)}else(e.status===m.ADDED||e.status===m.QUEUED)&&(e.status=m.CANCELED,this.emit("canceled",e),this.options.uploadMultiple&&this.emit("canceledmultiple",[e]));if(this.options.autoProcessQueue)return this.processQueue()}resolveOption(e,...n){return typeof e=="function"?e.apply(this,n):e}uploadFile(e){return this.uploadFiles([e])}uploadFiles(e){this._transformFiles(e,n=>{if(this.options.chunking){let t=n[0];e[0].upload.chunked=this.options.chunking&&(this.options.forceChunking||t.size>this.options.chunkSize),e[0].upload.totalChunkCount=Math.ceil(t.size/this.options.chunkSize)}if(e[0].upload.chunked){let t=e[0],i=n[0];t.upload.chunks=[];let r=()=>{let l=0;for(;t.upload.chunks[l]!==void 0;)l++;if(l>=t.upload.totalChunkCount)return;let o=l*this.options.chunkSize,p=Math.min(o+this.options.chunkSize,i.size),g={name:this._getParamName(0),data:i.webkitSlice?i.webkitSlice(o,p):i.slice(o,p),filename:t.upload.filename,chunkIndex:l};t.upload.chunks[l]={file:t,index:l,dataBlock:g,status:m.UPLOADING,progress:0,retries:0},this._uploadData(e,[g])};if(t.upload.finishedChunkUpload=(l,o)=>{let p=!0;l.status=m.SUCCESS,l.dataBlock=null,l.response=l.xhr.responseText,l.responseHeaders=l.xhr.getAllResponseHeaders(),l.xhr=null;for(let g=0;g{this._finished(e,o,null)})},this.options.parallelChunkUploads)for(let l=0;l{this._finishedUploading(e,t,g)},t.ontimeout=()=>{this._handleUploadError(e,t,`Request timedout after ${this.options.timeout/1e3} seconds`)},t.onerror=()=>{this._handleUploadError(e,t)};let o=t.upload!=null?t.upload:t;o.onprogress=g=>this._updateFilesUploadProgress(e,t,g);let p=this.options.defaultHeaders?{Accept:"application/json","Cache-Control":"no-cache","X-Requested-With":"XMLHttpRequest"}:{};this.options.binaryBody&&(p["Content-Type"]=e[0].type),this.options.headers&&ee(p,this.options.headers);for(let g in p){let E=p[g];E&&t.setRequestHeader(g,E)}if(this.options.binaryBody){for(let g of e)this.emit("sending",g,t);this.options.uploadMultiple&&this.emit("sendingmultiple",e,t),this.submitRequest(t,null,e)}else{let g=new FormData;if(this.options.params){let E=this.options.params;typeof E=="function"&&(E=E.call(this,e,t,e[0].upload.chunked?this._getChunk(e[0],t):null));for(let x in E){let T=E[x];if(Array.isArray(T))for(let b=0;b{t[r]=l,++i===e.length&&n(t)})}_addFormElementData(e){if(this.element.tagName==="FORM")for(let n of this.element.querySelectorAll("input, textarea, select, button")){let t=n.getAttribute("name"),i=n.getAttribute("type");if(i&&(i=i.toLowerCase()),!(typeof t>"u"||t===null))if(n.tagName==="SELECT"&&n.hasAttribute("multiple"))for(let r of n.options)r.selected&&e.append(t,r.value);else(!i||i!=="checkbox"&&i!=="radio"||n.checked)&&e.append(t,n.value)}}_updateFilesUploadProgress(e,n,t){if(e[0].upload.chunked){let i=e[0],r=this._getChunk(i,n);t?(r.progress=100*t.loaded/t.total,r.total=t.total,r.bytesSent=t.loaded):(r.progress=100,r.bytesSent=r.total),i.upload.progress=0,i.upload.total=0,i.upload.bytesSent=0;for(let l=0;lthis.options.renameFilename.call(this,l.name,l)),typeof this.options.method=="string"&&(this.options.method=this.options.method.toUpperCase()),(t=this.getExistingFallback())&&t.parentNode&&t.parentNode.removeChild(t),this.options.previewsContainer!==!1&&(this.options.previewsContainer?this.previewsContainer=m.getElement(this.options.previewsContainer,"previewsContainer"):this.previewsContainer=this.element),this.options.clickable&&(this.options.clickable===!0?this.clickableElements=[this.element]:this.clickableElements=m.getElements(this.options.clickable,"clickable")),this.init()}}m.initClass();m.options={};m.optionsForElement=function(s){if(s.getAttribute("id"))return m.options[we(s.getAttribute("id"))]};m.instances=[];m.forElement=function(s){if(typeof s=="string"&&(s=document.querySelector(s)),(s!=null?s.dropzone:void 0)==null)throw new Error("No Dropzone found for given element. This is probably because you're trying to access it before Dropzone had the time to initialize. Use the `init` option to setup any additional observers on your Dropzone.");return s.dropzone};m.discover=function(){let s;if(document.querySelectorAll)s=document.querySelectorAll(".dropzone");else{s=[];let e=n=>(()=>{let t=[];for(let i of n)/(^| )dropzone($| )/.test(i.className)?t.push(s.push(i)):t.push(void 0);return t})();e(document.getElementsByTagName("div")),e(document.getElementsByTagName("form"))}return(()=>{let e=[];for(let n of s)m.optionsForElement(n)!==!1?e.push(new m(n)):e.push(void 0);return e})()};m.blockedBrowsers=[/opera.*(Macintosh|Windows Phone).*version\/12/i];m.isBrowserSupported=function(){let s=!0;if(window.File&&window.FileReader&&window.FileList&&window.Blob&&window.FormData&&document.querySelector)if(!("classList"in document.createElement("a")))s=!1;else{m.blacklistedBrowsers!==void 0&&(m.blockedBrowsers=m.blacklistedBrowsers);for(let e of m.blockedBrowsers)if(e.test(navigator.userAgent)){s=!1;continue}}else s=!1;return s};m.dataURItoBlob=function(s){let e=atob(s.split(",")[1]),n=s.split(",")[0].split(":")[1].split(";")[0],t=new ArrayBuffer(e.length),i=new Uint8Array(t);for(let r=0,l=e.length,o=0<=l;o?r<=l:r>=l;o?r++:r--)i[r]=e.charCodeAt(r);return new Blob([t],{type:n})};const xe=(s,e)=>s.filter(n=>n!==e).map(n=>n),we=s=>s.replace(/[\-_](\w)/g,e=>e.charAt(1).toUpperCase());m.createElement=function(s){let e=document.createElement("div");return e.innerHTML=s,e.childNodes[0]};m.elementInside=function(s,e){if(s===e)return!0;for(;s=s.parentNode;)if(s===e)return!0;return!1};m.getElement=function(s,e){let n;if(typeof s=="string"?n=document.querySelector(s):s.nodeType!=null&&(n=s),n==null)throw new Error(`Invalid \`${e}\` option provided. Please provide a CSS selector or a plain HTML element.`);return n};m.getElements=function(s,e){let n,t;if(s instanceof Array){t=[];try{for(n of s)t.push(this.getElement(n,e))}catch{t=null}}else if(typeof s=="string"){t=[];for(n of document.querySelectorAll(s))t.push(n)}else s.nodeType!=null&&(t=[s]);if(t==null||!t.length)throw new Error(`Invalid \`${e}\` option provided. Please provide a CSS selector, a plain HTML element or a list of those.`);return t};m.confirm=function(s,e,n){if(window.confirm(s))return e();if(n!=null)return n()};m.isValidFile=function(s,e){if(!e)return!0;e=e.split(",");let n=s.type,t=n.replace(/\/.*$/,"");for(let i of e)if(i=i.trim(),i.charAt(0)==="."){if(s.name.toLowerCase().indexOf(i.toLowerCase(),s.name.length-i.length)!==-1)return!0}else if(/\/\*$/.test(i)){if(t===i.replace(/\/.*$/,""))return!0}else if(n===i)return!0;return!1};typeof jQuery<"u"&&jQuery!==null&&(jQuery.fn.dropzone=function(s){return this.each(function(){return new m(this,s)})});m.ADDED="added";m.QUEUED="queued";m.ACCEPTED=m.QUEUED;m.UPLOADING="uploading";m.PROCESSING=m.UPLOADING;m.CANCELED="canceled";m.ERROR="error";m.SUCCESS="success";let Te=function(s){s.naturalWidth;let e=s.naturalHeight,n=document.createElement("canvas");n.width=1,n.height=e;let t=n.getContext("2d");t.drawImage(s,0,0);let{data:i}=t.getImageData(1,0,1,e),r=0,l=e,o=e;for(;o>r;)i[(o-1)*4+3]===0?l=o:r=o,o=l+r>>1;let p=o/e;return p===0?1:p};var be=function(s,e,n,t,i,r,l,o,p,g){let E=Te(e);return s.drawImage(e,n,t,i,r,l,o,p,g/E)};class ce{static initClass(){this.KEY_STR="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}static encode64(e){let n="",t,i,r="",l,o,p,g="",E=0;for(;t=e[E++],i=e[E++],r=e[E++],l=t>>2,o=(t&3)<<4|i>>4,p=(i&15)<<2|r>>6,g=r&63,isNaN(i)?p=g=64:isNaN(r)&&(g=64),n=n+this.KEY_STR.charAt(l)+this.KEY_STR.charAt(o)+this.KEY_STR.charAt(p)+this.KEY_STR.charAt(g),t=i=r="",l=o=p=g="",Ee.length)break}return t}static decode64(e){let n,t,i="",r,l,o,p="",g=0,E=[];for(/[^A-Za-z0-9\+\/\=]/g.exec(e)&&console.warn(`There were invalid base64 characters in the input text. Valid base64 characters are A-Z, a-z, 0-9, '+', '/',and '=' -Expect errors in decoding.`),e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");r=this.KEY_STR.indexOf(e.charAt(g++)),l=this.KEY_STR.indexOf(e.charAt(g++)),o=this.KEY_STR.indexOf(e.charAt(g++)),p=this.KEY_STR.indexOf(e.charAt(g++)),n=r<<2|l>>4,t=(l&15)<<4|o>>2,i=(o&3)<<6|p,E.push(n),o!==64&&E.push(t),p!==64&&E.push(i),n=t=i="",r=l=o=p="",g{},onShow:()=>{},onToggle:()=>{}},me="STATIC_CLIENT_ID",Me=3,Ae=3,Pe=8,k="http://192.168.0.2",D="STATIC_BEARER",De="0421a23",a=new X(Fe,W),qe="https://docs.google.com/viewerng/viewer?url=",d=new X(ke,W),Ue=new X(Re,W),Ne=new X(Le,W),pe=new X(ze,W),q=document.getElementById("submitBtn"),He=new X(Ce,W),se=document.getElementById("scsModalBtn"),he=document.getElementById("dropzoneArea"),Oe=document.getElementById("dropzoneAreaCnv"),je=document.getElementById("dropzoneAreaSingle"),_="/storage/upload/",_e=new X(Se,W),ie=document.getElementById("footer"),re=document.getElementById("whatsNew");let M,I;var C=document.getElementById("altTitleMessageModal"),u=document.getElementById("altSubMessageModal"),c=document.getElementById("errMessageModal"),y=document.getElementById("errSubMessageModal"),Xe=document.getElementById("err-list"),f=document.getElementById("err-list-title"),le=document.getElementById("scsMessageModalNotify"),F=document.getElementById("titleMessageModal"),A=[],B=!0,z=0,L=0;q&&(q.onclick=function(s){F.innerText!=="Processing document"?F.innerText="Preparing document":document.getElementById("html")==null&&document.getElementById("cnvFrPDF")==null?F.innerText="Processing document":document.getElementById("html")!==null?F.innerText="Processing URL":F.innerText="Processing document",c.style.visibility=null,y.style.visibility=null,u.style.display="none",a.hide(),d.show(),B?et().then(function(){Ze().then(function(){d.hide(),document.getElementById("html")!==null?ae(s):z>0&&L>0?z==L?ae(s):(s.preventDefault(),c.innerText="Sorry, we're still uploading your documents",y.innerText="",f.innerText="Error message",v(),h(z+" of "+L+" documents are still uploading"),u.style=null,d.hide(),a.show()):(s.preventDefault(),c.innerText="Document can not be processed !",y.innerText="",f.innerText="Error message",v(),h("No file has been chosen"),u.style=null,d.hide(),a.show())}).catch(function(e){a.hide(),c.innerText="There was unexpected error !",y.innerText="",f.innerText="Error message",v(),h(e.xhrBalanceResponse),u.style=null,d.hide(),a.show()})}).catch(function(e){a.hide(),c.innerText="There was unexpected error !",y.innerText="",f.innerText="Error message",v(),h("Versioning validation failed"),h(e.versioningMessage),u.style=null,d.hide(),a.show()}):(s.preventDefault(),c.innerText="Sorry, we're still processing your documents",y.style.visibility=null,u.style.visibility=null,u.style.display="none",d.hide(),a.show())});se&&(se.onclick=function(){ie&&ie.scrollIntoView({behavior:"smooth",block:"end"})});re&&(re.onclick=function(){F.innerText="Fetching latest update",d.show(),Ve().then(s=>{const e=document.getElementById("versionHistoryLayout");e.innerHTML="",s.versionFetchResponse.forEach((n,t)=>{const i=document.createElement("ul"),r=document.createElement("div"),l=document.createElement("h2"),o=document.createElement("time");i.className="font-quicksand font-semibold text-sm text-dt1 list-disc list-inside overflow-y-auto mx-2",r.className="version-entry mb-4",l.className="flex items-start mb-1 text-lg font-semibold font-quicksand text-pc",o.className="block mb-3 text-sm font-normal leading-none font-quicksand text-dt3",l.innerText="Hana PDF v"+n.version,t==0&&(l.innerHTML+='Latest'),o.innerText="Released on "+n.release_date,n.changelog.forEach(p=>{const g=document.createElement("li");g.textContent=p,i.appendChild(g)}),r.appendChild(l),r.appendChild(o),r.appendChild(i),e.appendChild(r)}),F.innerText="Preparing document",d.hide(),_e.show()}).catch(function(s){F.innerText="Preparing document",d.hide(),a.hide(),c.innerText="There was unexpected error !",y.innerText="",f.innerText="Error message",v(),h(s.versionFetchMessage),u.style=null,d.hide(),a.show()})});if(he){let s=new m("#dropzoneArea",{url:`${k}/api/v1/file/upload`,paramName:"file",maxFilesize:25,maxFiles:5,acceptedFiles:"application/pdf",addRemoveLinks:!0,dictDefaultMessage:"",dictRemoveFile:"Remove",timeout:6e5,previewTemplate:'
',clickable:!0,headers:{Authorization:"Bearer "+D,"X-Requested-With":"XMLHttpRequest",Accept:"application/json"},init:function(){document.getElementById("dropzoneUploadInit").addEventListener("click",function(){s.hiddenFileInput.click()}),document.getElementById("dropzoneUploadExt").addEventListener("click",function(){s.files.length>=4?document.getElementById("dropzoneUiExt").classList.add("hidden"):(s.hiddenFileInput.click(),document.getElementById("dropzoneUiExt").classList.remove("hidden"))}),this.on("addedfile",function(e){L=s.files.length;var n=document.getElementsByClassName("dz-remove"),t=document.querySelectorAll('[data-dz-name=""]');document.querySelector(".dz-default.dz-message").style.display="none",document.getElementById("dropzoneUiInit").style.display="none";for(var i=0;i=4?(document.getElementById("dropzoneUiExt").classList.add("hidden"),s.hiddenFileInput.setAttribute("disabled","disabled")):(document.getElementById("dropzoneUiExt").classList.remove("hidden"),s.hiddenFileInput.removeAttribute("disabled","disabled")),Object.assign(q.style,{backgroundColor:"#4DAAAA",borderColor:"transparent"});var r=document.querySelectorAll(".prvBtn"),l=document.querySelectorAll(".rmvBtn");r.forEach(function(o){o.addEventListener("click",function(p){var g=p.target.closest(".dz-file-preview"),E=g.querySelector(".dz-filename span"),x=$(E.innerText),T=k+_+x,b=new AdobeDC.View({clientId:me,divId:"adobe-dc-view"});b.previewFile({content:{location:{url:T}},metaData:{fileName:x}},{embedMode:"SIZED_CONTAINER",focusOnRendering:!0,showDownloadPDF:!1}),pe.show()})}),l.forEach(function(o){o.addEventListener("click",function(){var p=document.getElementById("adobe-dc-view");p&&(p.innerHTML='
@include('includes.footer')
+@include('includes.head')
@include('includes.header')
@include('includes.modal') @include('includes.pdf-preview')
@yield('content')
@include('includes.footer')
diff --git a/resources/views/layouts/main-layout.blade.php b/resources/views/layouts/main-layout.blade.php index 97b4f7e..a83e591 100644 --- a/resources/views/layouts/main-layout.blade.php +++ b/resources/views/layouts/main-layout.blade.php @@ -1 +1 @@ -@include('includes.head')
@include('includes.header')
@include('includes.modal') @include('includes.pdf-preview')
@yield('content')
+@include('includes.head')
@include('includes.header')
@include('includes.modal') @include('includes.pdf-preview')
@yield('content')