@necrolab/dashboard 0.4.221 → 0.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.prettierrc +27 -1
- package/.vscode/extensions.json +1 -1
- package/README.md +64 -2
- package/artwork/image.png +0 -0
- package/backend/api.js +26 -24
- package/backend/auth.js +2 -2
- package/backend/batching.js +1 -1
- package/backend/endpoints.js +8 -11
- package/backend/index.js +2 -2
- package/backend/mock-data.js +27 -36
- package/backend/mock-src/classes/logger.js +5 -7
- package/backend/mock-src/classes/utils.js +3 -2
- package/backend/mock-src/ticketmaster.js +4 -4
- package/backend/validator.js +2 -2
- package/config/configs.json +0 -1
- package/dev-server.js +134 -0
- package/exit +209 -0
- package/index.html +80 -8
- package/index.js +1 -1
- package/jsconfig.json +16 -0
- package/package.json +39 -25
- package/postcss.config.js +1 -1
- package/postinstall.js +124 -20
- package/public/android-chrome-192x192.png +0 -0
- package/public/android-chrome-512x512.png +0 -0
- package/public/apple-touch-icon.png +0 -0
- package/public/favicon-16x16.png +0 -0
- package/public/favicon-32x32.png +0 -0
- package/public/favicon.ico +0 -0
- package/public/img/logo_trans.png +0 -0
- package/public/img/necro_logo.png +0 -0
- package/public/manifest.json +16 -10
- package/public/reconnect-logo.png +0 -0
- package/run +176 -9
- package/src/App.vue +498 -85
- package/src/assets/css/base/reset.scss +43 -0
- package/src/assets/css/base/scroll.scss +114 -0
- package/src/assets/css/base/typography.scss +37 -0
- package/src/assets/css/components/buttons.scss +216 -0
- package/src/assets/css/components/forms.scss +221 -0
- package/src/assets/css/components/modals.scss +13 -0
- package/src/assets/css/components/tables.scss +27 -0
- package/src/assets/css/components/toasts.scss +100 -0
- package/src/assets/css/main.scss +202 -122
- package/src/assets/img/background.svg +2 -2
- package/src/assets/img/background.svg.backup +11 -0
- package/src/assets/img/logo_trans.png +0 -0
- package/src/components/Auth/LoginForm.vue +95 -11
- package/src/components/Editors/Account/Account.vue +116 -40
- package/src/components/Editors/Account/AccountCreator.vue +88 -39
- package/src/components/Editors/Account/AccountView.vue +102 -34
- package/src/components/Editors/Account/CreateAccount.vue +80 -32
- package/src/components/Editors/Profile/CreateProfile.vue +269 -83
- package/src/components/Editors/Profile/Profile.vue +132 -47
- package/src/components/Editors/Profile/ProfileCountryChooser.vue +82 -20
- package/src/components/Editors/Profile/ProfileView.vue +89 -32
- package/src/components/Editors/TagLabel.vue +67 -6
- package/src/components/Editors/TagToggle.vue +7 -2
- package/src/components/Filter/Filter.vue +288 -71
- package/src/components/Filter/FilterPreview.vue +202 -31
- package/src/components/Filter/PriceSortToggle.vue +76 -6
- package/src/components/Table/Header.vue +1 -1
- package/src/components/Table/Row.vue +1 -1
- package/src/components/Table/Table.vue +19 -2
- package/src/components/Tasks/CheckStock.vue +6 -8
- package/src/components/Tasks/Controls/DesktopControls.vue +27 -17
- package/src/components/Tasks/Controls/MobileControls.vue +8 -45
- package/src/components/Tasks/CreateTaskAXS.vue +80 -72
- package/src/components/Tasks/CreateTaskTM.vue +95 -141
- package/src/components/Tasks/MassEdit.vue +4 -6
- package/src/components/Tasks/QuickSettings.vue +199 -30
- package/src/components/Tasks/ScrapeVenue.vue +5 -6
- package/src/components/Tasks/Stats.vue +50 -24
- package/src/components/Tasks/Task.vue +384 -179
- package/src/components/Tasks/TaskLabel.vue +2 -2
- package/src/components/Tasks/TaskView.vue +136 -48
- package/src/components/Tasks/Utilities.vue +25 -10
- package/src/components/Tasks/ViewTask.vue +321 -0
- package/src/components/icons/Bag.vue +1 -1
- package/src/components/icons/Check.vue +5 -0
- package/src/components/icons/Close.vue +21 -0
- package/src/components/icons/CloseX.vue +5 -0
- package/src/components/icons/Eye.vue +6 -0
- package/src/components/icons/Key.vue +21 -0
- package/src/components/icons/Loyalty.vue +1 -1
- package/src/components/icons/Mail.vue +2 -2
- package/src/components/icons/Pencil.vue +21 -0
- package/src/components/icons/Play.vue +2 -2
- package/src/components/icons/Profile.vue +18 -0
- package/src/components/icons/Reload.vue +4 -5
- package/src/components/icons/Sandclock.vue +2 -2
- package/src/components/icons/Sell.vue +21 -0
- package/src/components/icons/Spinner.vue +42 -0
- package/src/components/icons/SquareCheck.vue +18 -0
- package/src/components/icons/SquareUncheck.vue +18 -0
- package/src/components/icons/Stadium.vue +1 -1
- package/src/components/icons/Wildcard.vue +18 -0
- package/src/components/icons/index.js +26 -1
- package/src/components/ui/Modal.vue +107 -13
- package/src/components/ui/Navbar.vue +175 -40
- package/src/components/ui/ReconnectIndicator.vue +351 -55
- package/src/components/ui/Splash.vue +5 -35
- package/src/components/ui/controls/CountryChooser.vue +200 -62
- package/src/components/ui/controls/atomic/Checkbox.vue +119 -10
- package/src/components/ui/controls/atomic/Dropdown.vue +216 -39
- package/src/components/ui/controls/atomic/LoadingButton.vue +45 -0
- package/src/components/ui/controls/atomic/MultiDropdown.vue +300 -37
- package/src/components/ui/controls/atomic/Switch.vue +53 -25
- package/src/composables/useClickOutside.js +21 -0
- package/src/composables/useDropdownPosition.js +174 -0
- package/src/libs/Filter.js +60 -24
- package/src/registerServiceWorker.js +1 -1
- package/src/stores/connection.js +4 -4
- package/src/stores/sampleData.js +172 -199
- package/src/stores/ui.js +55 -20
- package/src/stores/utils.js +30 -4
- package/src/types/index.js +41 -0
- package/src/utils/debug.js +1 -0
- package/src/views/Accounts.vue +116 -50
- package/src/views/Console.vue +394 -77
- package/src/views/Editor.vue +1176 -123
- package/src/views/FilterBuilder.vue +528 -250
- package/src/views/Login.vue +75 -14
- package/src/views/Profiles.vue +119 -34
- package/src/views/Tasks.vue +266 -98
- package/static/offline.html +192 -50
- package/switch-branch.sh +41 -0
- package/tailwind.config.js +119 -27
- package/vite.config.js +73 -16
- package/workbox-config.cjs +63 -0
- package/ICONS.md +0 -21
- package/public/img/background.svg +0 -14
- package/public/img/logo.png +0 -0
- package/public/img/logo_icon.png +0 -0
- package/public/img/logo_icon_2.png +0 -0
- package/src/assets/css/_input.scss +0 -143
- package/src/assets/img/logo.png +0 -0
- package/src/assets/img/logo_icon.png +0 -0
- package/src/assets/img/logo_icon_2.png +0 -0
- package/vue.config.js +0 -32
- package/workbox-config.js +0 -7
package/src/stores/ui.js
CHANGED
|
@@ -7,7 +7,7 @@ import { timeDifference, betterSort, sortTaskIds } from "@/stores/utils";
|
|
|
7
7
|
|
|
8
8
|
import mockTaskData from "@/stores/sampleData.js";
|
|
9
9
|
import { useRouter } from "vue-router";
|
|
10
|
-
|
|
10
|
+
import { DEBUG } from "@/utils/debug";
|
|
11
11
|
|
|
12
12
|
const ALL_SELECTED = 0;
|
|
13
13
|
const SOME_SELECTED = 1;
|
|
@@ -26,13 +26,13 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
26
26
|
const tasks = ref({});
|
|
27
27
|
|
|
28
28
|
const showSpinner = ref(false);
|
|
29
|
-
const botVersion = ref("
|
|
29
|
+
const botVersion = ref("0.0.0");
|
|
30
30
|
|
|
31
31
|
const spinnerMessage = ref("");
|
|
32
32
|
|
|
33
33
|
const profile = ref({
|
|
34
34
|
profileTags: [],
|
|
35
|
-
|
|
35
|
+
tags: [],
|
|
36
36
|
admin: false,
|
|
37
37
|
name: ""
|
|
38
38
|
});
|
|
@@ -57,6 +57,7 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
57
57
|
const taskIdOrder = ref(Object.keys(tasks.value));
|
|
58
58
|
const modalData = ref({});
|
|
59
59
|
const taskFilter = ref("All"); // 'All' or 'Checkout'
|
|
60
|
+
const selectedTaskForView = ref(null);
|
|
60
61
|
const connection = new ConnectionHandler();
|
|
61
62
|
|
|
62
63
|
const startPoint = ref(0);
|
|
@@ -103,8 +104,10 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
103
104
|
const t1 = new Date();
|
|
104
105
|
for (const [key, value] of Object.entries(tasks.value)) {
|
|
105
106
|
if (value.expirationTime)
|
|
106
|
-
tasks.value[key]._timeLeftString =
|
|
107
|
-
|
|
107
|
+
tasks.value[key]._timeLeftString =
|
|
108
|
+
value.expirationTime == "Invalid Date"
|
|
109
|
+
? "No Cartholds"
|
|
110
|
+
: timeDifference(Date.parse(value.expirationTime), t1.getTime());
|
|
108
111
|
else tasks.value[key]._timeLeftString = undefined;
|
|
109
112
|
}
|
|
110
113
|
|
|
@@ -138,7 +141,11 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
138
141
|
connection.init("/api/updates?type=tasks");
|
|
139
142
|
|
|
140
143
|
const pd = (e) => {
|
|
141
|
-
if (
|
|
144
|
+
if (
|
|
145
|
+
!e.target.closest(".scrollable") &&
|
|
146
|
+
!e.target.closest(".dropdown-menu") &&
|
|
147
|
+
!e.target.closest(".option-list")
|
|
148
|
+
) {
|
|
142
149
|
e.preventDefault();
|
|
143
150
|
}
|
|
144
151
|
};
|
|
@@ -229,15 +236,20 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
229
236
|
let relevantTasks = Object.values(tasks.value).filter((t) => t.siteId === currentCountry.value.siteId);
|
|
230
237
|
if (currentEvent.value) relevantTasks = relevantTasks.filter((t) => t.eventId === currentEvent.value);
|
|
231
238
|
|
|
232
|
-
queueStats.value.total = 0;
|
|
233
239
|
queueStats.value.queued = relevantTasks.filter((t) => t.inQueue).length || 0;
|
|
234
|
-
queueStats.value.show = queueStats.value.total > 0;
|
|
235
240
|
const sleepingStatuses = ["sleeping in queue", "waiting for drop", "waiting for carting", "waiting for queue"];
|
|
236
241
|
queueStats.value.sleeping = relevantTasks.filter((t) =>
|
|
237
242
|
sleepingStatuses.includes(t.status.toLowerCase())
|
|
238
243
|
).length;
|
|
239
|
-
const positions = relevantTasks
|
|
244
|
+
const positions = relevantTasks
|
|
245
|
+
.map((t) => t.queuePosition)
|
|
246
|
+
.filter((e) => !isNaN(e))
|
|
247
|
+
.filter(Boolean);
|
|
240
248
|
queueStats.value.nextQueuePasses = positions.sort((a, b) => a - b);
|
|
249
|
+
|
|
250
|
+
// Only show stats if there are any queued tasks, sleeping tasks, or queue positions
|
|
251
|
+
queueStats.value.show =
|
|
252
|
+
queueStats.value.queued > 0 || queueStats.value.sleeping > 0 || queueStats.value.nextQueuePasses.length > 0;
|
|
241
253
|
};
|
|
242
254
|
|
|
243
255
|
const toggleModal = (name, clearValue = false) => {
|
|
@@ -377,6 +389,7 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
377
389
|
activeModal,
|
|
378
390
|
toggleModal,
|
|
379
391
|
modalData,
|
|
392
|
+
selectedTaskForView,
|
|
380
393
|
|
|
381
394
|
// sorting
|
|
382
395
|
toggleSort: (sort = null) => {
|
|
@@ -481,11 +494,11 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
481
494
|
},
|
|
482
495
|
|
|
483
496
|
toggleProfileSelected: (id) => {
|
|
484
|
-
const idx = profiles.value.findIndex((p) => p.
|
|
497
|
+
const idx = profiles.value.findIndex((p) => p.id === id);
|
|
485
498
|
profiles.value[idx].selected = !profiles.value[idx].selected;
|
|
486
499
|
},
|
|
487
500
|
toggleAccountSelected: (id) => {
|
|
488
|
-
const idx = accounts.value.findIndex((p) => p.
|
|
501
|
+
const idx = accounts.value.findIndex((p) => p.id === id);
|
|
489
502
|
accounts.value[idx].selected = !accounts.value[idx].selected;
|
|
490
503
|
},
|
|
491
504
|
|
|
@@ -496,8 +509,30 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
496
509
|
massEditPresaleCode: (eventId, presaleCode) => connection.sendMassEditPresaleCode(eventId, presaleCode),
|
|
497
510
|
|
|
498
511
|
// alerts
|
|
499
|
-
showError: (err) =>
|
|
500
|
-
|
|
512
|
+
showError: (err) =>
|
|
513
|
+
toast.error(err, {
|
|
514
|
+
autoClose: 1400,
|
|
515
|
+
pauseOnHover: false,
|
|
516
|
+
hideProgressBar: false,
|
|
517
|
+
closeOnClick: true,
|
|
518
|
+
pauseOnFocusLoss: false,
|
|
519
|
+
transition: "slide",
|
|
520
|
+
position: "top-right",
|
|
521
|
+
closeButton: true,
|
|
522
|
+
newestOnTop: true
|
|
523
|
+
}),
|
|
524
|
+
showSuccess: (msg) =>
|
|
525
|
+
toast.success(msg, {
|
|
526
|
+
autoClose: 1400,
|
|
527
|
+
pauseOnHover: false,
|
|
528
|
+
hideProgressBar: false,
|
|
529
|
+
closeOnClick: true,
|
|
530
|
+
pauseOnFocusLoss: false,
|
|
531
|
+
transition: "slide",
|
|
532
|
+
position: "top-right",
|
|
533
|
+
closeButton: true,
|
|
534
|
+
newestOnTop: true
|
|
535
|
+
}),
|
|
501
536
|
// Country
|
|
502
537
|
currentCountry,
|
|
503
538
|
setCurrentCountry: (country, closeModal, newModule) => {
|
|
@@ -513,8 +548,8 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
513
548
|
// Event
|
|
514
549
|
currentEvent,
|
|
515
550
|
setCurrentEvent: (event) => {
|
|
516
|
-
logger.Info("Setting current event", event);
|
|
517
|
-
currentEvent.value = event;
|
|
551
|
+
if (event) logger.Info("Setting current event to:", event);
|
|
552
|
+
currentEvent.value = event?.match(/\s\((.*?)\)$/)?.[1] || "";
|
|
518
553
|
localStorage.setItem("current-event", currentEvent.value);
|
|
519
554
|
refreshQueueStats();
|
|
520
555
|
},
|
|
@@ -530,26 +565,26 @@ export const useUIStore = defineStore("ui", () => {
|
|
|
530
565
|
accounts,
|
|
531
566
|
addAccount: (acc) => {
|
|
532
567
|
if (!DEBUG) return connection.sendSaveAccount(acc);
|
|
533
|
-
const isEdit = accounts.value.findIndex((p) => p.
|
|
568
|
+
const isEdit = accounts.value.findIndex((p) => p.id === acc.id);
|
|
534
569
|
if (DEBUG && isEdit !== -1) {
|
|
535
570
|
Object.keys(acc).forEach((k) => (accounts.value[isEdit][k] = acc[k]));
|
|
536
|
-
} else accounts.value.push({ ...acc,
|
|
571
|
+
} else accounts.value.push({ ...acc, id: Math.random() });
|
|
537
572
|
},
|
|
538
573
|
setAccounts: (accs) => accounts.value.push(...accs),
|
|
539
574
|
profiles,
|
|
540
575
|
addProfile: (profile) => {
|
|
541
576
|
if (!DEBUG) return connection.sendSaveProfile(profile);
|
|
542
|
-
const isEdit = profiles.value.findIndex((p) => p.
|
|
577
|
+
const isEdit = profiles.value.findIndex((p) => p.id === profile.id);
|
|
543
578
|
|
|
544
579
|
if (DEBUG && isEdit !== -1) {
|
|
545
580
|
Object.keys(profile).forEach((k) => (accounts.value[isEdit][k] = profile[k]));
|
|
546
581
|
} else {
|
|
547
|
-
profiles.value.push({ ...profile,
|
|
582
|
+
profiles.value.push({ ...profile, id: Math.random() });
|
|
548
583
|
}
|
|
549
584
|
},
|
|
550
585
|
deleteProfile: (id) => {
|
|
551
586
|
if (!DEBUG) return connection.sendDeleteProfile(id);
|
|
552
|
-
else profiles.value = profiles.value.filter((p) => p.
|
|
587
|
+
else profiles.value = profiles.value.filter((p) => p.id != id);
|
|
553
588
|
},
|
|
554
589
|
setProfiles: (profs) => (profiles.value = profs),
|
|
555
590
|
proxies,
|
package/src/stores/utils.js
CHANGED
|
@@ -361,7 +361,29 @@ const timeDifference = (date1, date2) => {
|
|
|
361
361
|
return str;
|
|
362
362
|
};
|
|
363
363
|
|
|
364
|
-
const
|
|
364
|
+
const parseAxsEventUrl = (url) => {
|
|
365
|
+
const HOST = "www.axs.com";
|
|
366
|
+
|
|
367
|
+
if (!url.startsWith("https://")) return { eventId: url };
|
|
368
|
+
if (!url.includes(`https://${HOST}`)) return {};
|
|
369
|
+
|
|
370
|
+
const siteMatch = url.match(new RegExp(`https://${HOST}(/uk)?`));
|
|
371
|
+
const eventMatch = url.match(/\/events\/(\d+)/);
|
|
372
|
+
const promoMatch = url.match(/\/promopage\/(\d+)/);
|
|
373
|
+
|
|
374
|
+
if (!siteMatch || !eventMatch) return {};
|
|
375
|
+
|
|
376
|
+
const siteId = siteMatch[1] === "/uk" ? "AXS_UK" : "AXS_US";
|
|
377
|
+
const eventId = eventMatch[1];
|
|
378
|
+
const promoId = promoMatch?.[1];
|
|
379
|
+
|
|
380
|
+
const result = { eventId, siteId };
|
|
381
|
+
if (promoId) result.promoId = promoId;
|
|
382
|
+
|
|
383
|
+
return result;
|
|
384
|
+
};
|
|
385
|
+
|
|
386
|
+
const parseTmEventUrl = (url) => {
|
|
365
387
|
if (!url.includes("https://")) {
|
|
366
388
|
return { eventId: url };
|
|
367
389
|
}
|
|
@@ -376,14 +398,14 @@ const parseEventUrl = (url) => {
|
|
|
376
398
|
};
|
|
377
399
|
};
|
|
378
400
|
|
|
379
|
-
const isEU = (siteId) => !["US", "AU", "UK", "
|
|
401
|
+
const isEU = (siteId) => !["US", "AU", "UK", "CA", "NZ", "IE"].includes(siteId.split("_")?.[1] || siteId);
|
|
380
402
|
|
|
381
403
|
const removeDuplicates = (arr) => [...new Set(arr)];
|
|
382
404
|
|
|
383
405
|
const pickRandom = (arr) => arr[Math.floor(Math.random() * arr.length)];
|
|
384
406
|
|
|
385
407
|
const fakeId = () => {
|
|
386
|
-
const cityInfo = pickRandom(cities.filter((x) => x
|
|
408
|
+
const cityInfo = pickRandom(cities.filter((x) => x[2] != "GA" && x[2] != "PR" && x[0] > 10000));
|
|
387
409
|
|
|
388
410
|
const profile = {
|
|
389
411
|
zipCode: String(cityInfo[0]),
|
|
@@ -509,6 +531,8 @@ function sortTaskIds(a, b) {
|
|
|
509
531
|
return aInfo.num - bInfo.num;
|
|
510
532
|
}
|
|
511
533
|
|
|
534
|
+
const firstUpper = (str) => `${str[0].toUpperCase()}${str.slice(1).toLowerCase()}`;
|
|
535
|
+
|
|
512
536
|
function betterSort(a, b) {
|
|
513
537
|
if (a === undefined || a === null) return b === undefined || b === null ? 0 : -1;
|
|
514
538
|
if (b === undefined || b === null) return 1;
|
|
@@ -542,7 +566,8 @@ export {
|
|
|
542
566
|
generateStreetAddress,
|
|
543
567
|
timeDifference,
|
|
544
568
|
sortAlphaNum,
|
|
545
|
-
|
|
569
|
+
parseAxsEventUrl,
|
|
570
|
+
parseTmEventUrl,
|
|
546
571
|
isEU,
|
|
547
572
|
removeDuplicates,
|
|
548
573
|
pickRandom,
|
|
@@ -550,5 +575,6 @@ export {
|
|
|
550
575
|
getCardType,
|
|
551
576
|
validateCard,
|
|
552
577
|
sortTaskIds,
|
|
578
|
+
firstUpper,
|
|
553
579
|
betterSort
|
|
554
580
|
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @typedef {Object} Task
|
|
3
|
+
* @property {string} accountTag
|
|
4
|
+
* @property {boolean} active
|
|
5
|
+
* @property {boolean} agedAccount
|
|
6
|
+
* @property {string} createdAt
|
|
7
|
+
* @property {string} createdAt
|
|
8
|
+
* @property {boolean} doNotPay
|
|
9
|
+
* @property {string} email
|
|
10
|
+
* @property {string} eventCity
|
|
11
|
+
* @property {string} eventDate
|
|
12
|
+
* @property {string} eventId
|
|
13
|
+
* @property {string} eventImage
|
|
14
|
+
* @property {string} eventLocalDate
|
|
15
|
+
* @property {string} eventName
|
|
16
|
+
* @property {string} eventUrl
|
|
17
|
+
* @property {string} eventVenue
|
|
18
|
+
* @property {string} expirationTime
|
|
19
|
+
* @property {boolean} isExpanded
|
|
20
|
+
* @property {boolean} loginAfterCart
|
|
21
|
+
* @property {boolean} manual
|
|
22
|
+
* @property {string} mode
|
|
23
|
+
* @property {string} openerLink
|
|
24
|
+
* @property {string} password
|
|
25
|
+
* @property {string} presaleCode
|
|
26
|
+
* @property {boolean} presaleMode
|
|
27
|
+
* @property {string} profileName
|
|
28
|
+
* @property {Array} profileTags
|
|
29
|
+
* @property {string} proxy
|
|
30
|
+
* @property {number} quantity
|
|
31
|
+
* @property {boolean} quickQueue
|
|
32
|
+
* @property {string} reservedTicketsList
|
|
33
|
+
* @property {boolean} selected
|
|
34
|
+
* @property {string} siteId
|
|
35
|
+
* @property {boolean} smartTimer
|
|
36
|
+
* @property {string} status
|
|
37
|
+
* @property {string} statusColor
|
|
38
|
+
* @property {string} taskId
|
|
39
|
+
* @property {string} venueName
|
|
40
|
+
* @property {string} _timeLeftString
|
|
41
|
+
*/
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const DEBUG = window.location.href.includes(":5173");
|
package/src/views/Accounts.vue
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
|
-
<div class="flex items-center">
|
|
3
|
+
<div class="flex items-center justify-between pt-5 pb-2">
|
|
4
4
|
<!-- Heading -->
|
|
5
|
-
<
|
|
6
|
-
|
|
7
|
-
<
|
|
8
|
-
|
|
5
|
+
<div class="flex items-center justify-center gap-4">
|
|
6
|
+
<MailIcon class="cursor-pointer smooth-hover text-white" />
|
|
7
|
+
<h4 class="text-base font-semibold text-light-300">
|
|
8
|
+
Accounts
|
|
9
|
+
<span class="text-sm font-medium text-light-400 pl-1">{{ ui.getSelectedAccounts().length }}</span>
|
|
10
|
+
</h4>
|
|
11
|
+
</div>
|
|
9
12
|
<ul class="mobile-icons">
|
|
10
13
|
<li>
|
|
11
14
|
<EyeToggle v-model="privacy" />
|
|
@@ -14,80 +17,67 @@
|
|
|
14
17
|
<button
|
|
15
18
|
:disabled="ui.disabledButtons['create-accounts']"
|
|
16
19
|
@click="ui.toggleModal('account-creator', true)"
|
|
17
|
-
|
|
18
|
-
<PlayIcon />
|
|
20
|
+
class="smooth-hover">
|
|
21
|
+
<PlayIcon class="w-4 h-4" />
|
|
19
22
|
</button>
|
|
20
23
|
</li>
|
|
21
24
|
<li>
|
|
22
25
|
<button
|
|
23
26
|
:disabled="ui.disabledButtons['add-accounts']"
|
|
24
27
|
@click="ui.toggleModal('create-account', true)"
|
|
25
|
-
|
|
26
|
-
<PlusIcon />
|
|
28
|
+
class="smooth-hover">
|
|
29
|
+
<PlusIcon class="w-4 h-4" />
|
|
27
30
|
</button>
|
|
28
31
|
</li>
|
|
29
32
|
</ul>
|
|
30
33
|
</div>
|
|
31
34
|
|
|
32
35
|
<div class="flex items-center mb-3">
|
|
33
|
-
<div class="flex sm:w-auto w-full justify-start items-center
|
|
36
|
+
<div class="unified-search-group flex sm:w-auto w-full justify-start items-center">
|
|
34
37
|
<TagToggle
|
|
35
|
-
class="smooth-hover
|
|
38
|
+
class="smooth-hover"
|
|
36
39
|
:options="['All', 'Enabled', 'Disabled']"
|
|
37
40
|
@change="(f) => (ui.search.accounts.show = f)"
|
|
38
|
-
|
|
41
|
+
:noBorder="true" />
|
|
39
42
|
<input
|
|
40
|
-
class="h-10 w-44 text-white text-sm p-2 bg-dark-500 flex items-center relative
|
|
43
|
+
class="h-10 w-44 text-white text-sm p-2 bg-dark-500 flex items-center relative"
|
|
41
44
|
placeholder="Search Email"
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
default="All"
|
|
49
|
-
:chosen="ui.search.accounts.show"
|
|
50
|
-
:options="['All', 'Enabled', 'Disabled']"
|
|
51
|
-
rightAmount="right-2"
|
|
52
|
-
/> -->
|
|
53
|
-
<!-- <TagToggle
|
|
54
|
-
class="smooth-hover rounded-r w-32"
|
|
55
|
-
:options="allTags"
|
|
56
|
-
@change="(f) => (ui.search.accounts.tag = f)"
|
|
57
|
-
/> -->
|
|
45
|
+
autocomplete="new-password"
|
|
46
|
+
data-dashlane-rid=""
|
|
47
|
+
data-dashlane-label=""
|
|
48
|
+
data-dashlane-classification=""
|
|
49
|
+
data-form-type="other"
|
|
50
|
+
v-model="ui.search.accounts.query" />
|
|
58
51
|
|
|
59
52
|
<Dropdown
|
|
60
|
-
class="
|
|
61
|
-
style="margin-left: 0 !important; border-width: 2px !important"
|
|
53
|
+
class="dropdown-unified relative z-50"
|
|
62
54
|
rightAmount="right-1"
|
|
63
55
|
default="Any"
|
|
64
56
|
:value="ui.search.accounts.tag"
|
|
65
57
|
:onClick="(f) => (ui.search.accounts.tag = f)"
|
|
66
58
|
:options="allTags"
|
|
67
|
-
:
|
|
68
|
-
|
|
59
|
+
:includeAdjacentButtons="true"
|
|
60
|
+
:capitalize="true" />
|
|
69
61
|
</div>
|
|
70
62
|
|
|
71
63
|
<div class="ml-auto gap-2 hidden lg:flex">
|
|
72
64
|
<div
|
|
73
|
-
class="bg-dark-400 justify-between px-4 w-44 flex text-white text-
|
|
74
|
-
>
|
|
65
|
+
class="bg-dark-400 border border-dark-650 justify-between px-4 w-44 flex text-white text-xs font-medium items-center rounded-md ml-auto h-10">
|
|
75
66
|
<p>Privacy</p>
|
|
76
67
|
<Switch class="scale-75" v-model="privacy" />
|
|
77
68
|
</div>
|
|
78
69
|
<button
|
|
79
70
|
:disabled="ui.disabledButtons['create-accounts']"
|
|
80
|
-
class="bg-dark-400 disabled:opacity-70 smooth-hover w-44 flex text-white text-
|
|
81
|
-
@click="ui.toggleModal('account-creator')"
|
|
82
|
-
|
|
83
|
-
|
|
71
|
+
class="bg-dark-400 disabled:opacity-70 smooth-hover border border-dark-650 hover:border-dark-700 w-44 flex text-white text-xs font-medium justify-center items-center rounded-md ml-auto h-10"
|
|
72
|
+
@click="ui.toggleModal('account-creator')">
|
|
73
|
+
Create Accounts
|
|
74
|
+
<PlayIcon class="ml-2" />
|
|
84
75
|
</button>
|
|
85
76
|
|
|
86
77
|
<button
|
|
87
78
|
:disabled="ui.disabledButtons['add-accounts']"
|
|
88
|
-
class="bg-dark-400 disabled:opacity-70 smooth-hover w-44 flex text-white text-
|
|
89
|
-
@click="ui.toggleModal('create-account')"
|
|
90
|
-
>
|
|
79
|
+
class="bg-dark-400 disabled:opacity-70 smooth-hover border border-dark-650 hover:border-dark-700 w-44 flex text-white text-xs font-medium justify-center items-center rounded-md ml-auto h-10"
|
|
80
|
+
@click="ui.toggleModal('create-account')">
|
|
91
81
|
Add Account
|
|
92
82
|
<PlusIcon class="ml-2" />
|
|
93
83
|
</button>
|
|
@@ -95,10 +85,10 @@
|
|
|
95
85
|
</div>
|
|
96
86
|
|
|
97
87
|
<!-- Tasks (Table) -->
|
|
98
|
-
<AccountView :
|
|
88
|
+
<AccountView :accounts="processedTasks" class="max-h-big-acc" />
|
|
99
89
|
|
|
100
90
|
<!-- Modal -->
|
|
101
|
-
<transition-group name="fade"
|
|
91
|
+
<transition-group name="fade">
|
|
102
92
|
<CreateAccount v-if="activeModal === 'create-account'" />
|
|
103
93
|
<AccountCreator v-if="activeModal === 'account-creator'" />
|
|
104
94
|
</transition-group>
|
|
@@ -108,20 +98,96 @@
|
|
|
108
98
|
.custom-dropdown-content {
|
|
109
99
|
top: 2.6rem !important;
|
|
110
100
|
left: -13px;
|
|
111
|
-
@apply border border-
|
|
101
|
+
@apply border border-dark-650;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
/* Unified search component group */
|
|
105
|
+
.unified-search-group {
|
|
106
|
+
border: 2px solid oklch(0.2809 0 0);
|
|
107
|
+
border-radius: 0.5rem;
|
|
108
|
+
overflow: hidden;
|
|
109
|
+
background: oklch(0.2603 0 0);
|
|
110
|
+
transition: all 0.15s ease;
|
|
111
|
+
display: flex;
|
|
112
|
+
|
|
113
|
+
:deep(.tag-toggle),
|
|
114
|
+
:deep(.dropdown),
|
|
115
|
+
input {
|
|
116
|
+
border: none !important;
|
|
117
|
+
border-width: 0 !important;
|
|
118
|
+
border-radius: 0 !important;
|
|
119
|
+
height: 40px !important;
|
|
120
|
+
background: transparent !important;
|
|
121
|
+
box-shadow: none !important;
|
|
122
|
+
min-width: fit-content !important;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
:deep(.tag-toggle) {
|
|
126
|
+
padding: 0;
|
|
127
|
+
border: 0 solid transparent !important;
|
|
128
|
+
border-top: 0 !important;
|
|
129
|
+
border-bottom: 0 !important;
|
|
130
|
+
border-left: 0 !important;
|
|
131
|
+
border-right: 0 !important;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
:deep(.tag-toggle button) {
|
|
135
|
+
font-size: 0.875rem;
|
|
136
|
+
padding: 0.5rem 0.75rem;
|
|
137
|
+
min-width: fit-content;
|
|
138
|
+
border: 0 solid transparent !important;
|
|
139
|
+
border-top: 0 !important;
|
|
140
|
+
border-bottom: 0 !important;
|
|
141
|
+
border-left: 0 !important;
|
|
142
|
+
border-right: 0 !important;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
:deep(.dropdown) {
|
|
146
|
+
width: 120px !important;
|
|
147
|
+
min-width: 120px !important;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
:deep(.dropdown-display) {
|
|
151
|
+
padding: 0 0.75rem;
|
|
152
|
+
font-size: 0.875rem;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
input {
|
|
156
|
+
padding-left: 0.75rem;
|
|
157
|
+
padding-right: 0.75rem;
|
|
158
|
+
flex: 1;
|
|
159
|
+
|
|
160
|
+
&::placeholder {
|
|
161
|
+
color: oklch(0.50 0 0);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
&:focus {
|
|
165
|
+
outline: none !important;
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
&:hover {
|
|
170
|
+
border-color: oklch(0.30 0 0);
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
&:focus-within {
|
|
174
|
+
border-color: oklch(0.72 0.15 145);
|
|
175
|
+
outline: 1px solid oklch(0.72 0.15 145);
|
|
176
|
+
outline-offset: 0;
|
|
177
|
+
}
|
|
112
178
|
}
|
|
113
179
|
.max-h-big-acc {
|
|
114
180
|
max-height: calc(100vh - 14rem);
|
|
115
|
-
overflow:
|
|
181
|
+
overflow: auto;
|
|
116
182
|
}
|
|
117
183
|
</style>
|
|
118
184
|
<script setup>
|
|
119
185
|
import { computed, watch, ref } from "vue";
|
|
120
|
-
import AccountView from "@/components/
|
|
121
|
-
import AccountCreator from "@/components/
|
|
122
|
-
import CreateAccount from "@/components/
|
|
186
|
+
import AccountView from "@/components/Editors/Account/AccountView.vue";
|
|
187
|
+
import AccountCreator from "@/components/Editors/Account/AccountCreator.vue";
|
|
188
|
+
import CreateAccount from "@/components/Editors/Account/CreateAccount.vue";
|
|
123
189
|
import { useUIStore } from "@/stores/ui";
|
|
124
|
-
import { PlusIcon, PlayIcon } from "@/components/icons";
|
|
190
|
+
import { PlusIcon, PlayIcon, MailIcon } from "@/components/icons";
|
|
125
191
|
import Dropdown from "@/components/ui/controls/atomic/Dropdown.vue";
|
|
126
192
|
import TagToggle from "@/components/Editors/TagToggle.vue";
|
|
127
193
|
import Switch from "@/components/ui/controls/atomic/Switch.vue";
|