拿掉 build files

This commit is contained in:
2022-07-18 16:33:23 +08:00
parent 41e2287bcb
commit 3707f158a3
31953 changed files with 0 additions and 4411796 deletions
-43
View File
@@ -1,43 +0,0 @@
// Extensions
import { Service } from '../service';
export class Application extends Service {
constructor() {
super(...arguments);
this.bar = 0;
this.top = 0;
this.left = 0;
this.insetFooter = 0;
this.right = 0;
this.bottom = 0;
this.footer = 0;
this.application = {
bar: {},
top: {},
left: {},
insetFooter: {},
right: {},
bottom: {},
footer: {}
};
}
register(uid, location, size) {
this.application[location] = {
[uid]: size
};
this.update(location);
}
unregister(uid, location) {
if (this.application[location][uid] == null) return;
delete this.application[location][uid];
this.update(location);
}
update(location) {
this[location] = Object.values(this.application[location]).reduce((acc, cur) => acc + cur, 0);
}
}
Application.property = 'application';
//# sourceMappingURL=index.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../src/services/application/index.ts"],"names":[],"mappings":"AAAA;AACA,SAAS,OAAT,QAAwB,YAAxB;AAKA,OAAM,MAAO,WAAP,SAA2B,OAA3B,CAAkC;AAAxC,EAAA,WAAA,GAAA;;AAGE,SAAA,GAAA,GAAM,CAAN;AAEA,SAAA,GAAA,GAAM,CAAN;AAEA,SAAA,IAAA,GAAO,CAAP;AAEA,SAAA,WAAA,GAAc,CAAd;AAEA,SAAA,KAAA,GAAQ,CAAR;AAEA,SAAA,MAAA,GAAS,CAAT;AAEA,SAAA,MAAA,GAAS,CAAT;AAEA,SAAA,WAAA,GAA4C;AAC1C,MAAA,GAAG,EAAE,EADqC;AAE1C,MAAA,GAAG,EAAE,EAFqC;AAG1C,MAAA,IAAI,EAAE,EAHoC;AAI1C,MAAA,WAAW,EAAE,EAJ6B;AAK1C,MAAA,KAAK,EAAE,EALmC;AAM1C,MAAA,MAAM,EAAE,EANkC;AAO1C,MAAA,MAAM,EAAE;AAPkC,KAA5C;AA+BD;;AArBC,EAAA,QAAQ,CACN,GADM,EAEN,QAFM,EAGN,IAHM,EAGM;AAEZ,SAAK,WAAL,CAAiB,QAAjB,IAA6B;AAAE,OAAC,GAAD,GAAO;AAAT,KAA7B;AAEA,SAAK,MAAL,CAAY,QAAZ;AACD;;AAED,EAAA,UAAU,CAAE,GAAF,EAAe,QAAf,EAAmC;AAC3C,QAAI,KAAK,WAAL,CAAiB,QAAjB,EAA2B,GAA3B,KAAmC,IAAvC,EAA6C;AAE7C,WAAO,KAAK,WAAL,CAAiB,QAAjB,EAA2B,GAA3B,CAAP;AACA,SAAK,MAAL,CAAY,QAAZ;AACD;;AAED,EAAA,MAAM,CAAE,QAAF,EAAsB;AAC1B,SAAK,QAAL,IAAiB,MAAM,CAAC,MAAP,CAAc,KAAK,WAAL,CAAiB,QAAjB,CAAd,EACd,MADc,CACP,CAAC,GAAD,EAAc,GAAd,KAAuC,GAAG,GAAG,GADtC,EAC4C,CAD5C,CAAjB;AAED;;AA/CqC;AAC/B,WAAA,CAAA,QAAA,GAA0B,aAA1B","sourcesContent":["// Extensions\nimport { Service } from '../service'\n\n// Types\nimport { TargetPropValues, TargetProp, Application as IApplication } from 'vuetify/types/services/application'\n\nexport class Application extends Service implements IApplication {\n static property: 'application' = 'application'\n\n bar = 0\n\n top = 0\n\n left = 0\n\n insetFooter = 0\n\n right = 0\n\n bottom = 0\n\n footer = 0\n\n application: Dictionary<TargetPropValues> = {\n bar: {},\n top: {},\n left: {},\n insetFooter: {},\n right: {},\n bottom: {},\n footer: {},\n }\n\n register (\n uid: number,\n location: TargetProp,\n size: number\n ) {\n this.application[location] = { [uid]: size }\n\n this.update(location)\n }\n\n unregister (uid: number, location: TargetProp) {\n if (this.application[location][uid] == null) return\n\n delete this.application[location][uid]\n this.update(location)\n }\n\n update (location: TargetProp) {\n this[location] = Object.values(this.application[location])\n .reduce((acc: number, cur: number): number => (acc + cur), 0)\n }\n}\n"],"sourceRoot":"","file":"index.js"}
-146
View File
@@ -1,146 +0,0 @@
// Extensions
import { Service } from '../service';
export class Breakpoint extends Service {
constructor(preset) {
super(); // Public
this.xs = false;
this.sm = false;
this.md = false;
this.lg = false;
this.xl = false;
this.xsOnly = false;
this.smOnly = false;
this.smAndDown = false;
this.smAndUp = false;
this.mdOnly = false;
this.mdAndDown = false;
this.mdAndUp = false;
this.lgOnly = false;
this.lgAndDown = false;
this.lgAndUp = false;
this.xlOnly = false; // Value is xs to match v2.x functionality
this.name = 'xs';
this.height = 0;
this.width = 0; // TODO: Add functionality to detect this dynamically in v3
// Value is true to match v2.x functionality
this.mobile = true;
this.resizeTimeout = 0;
const {
mobileBreakpoint,
scrollBarWidth,
thresholds
} = preset[Breakpoint.property];
this.mobileBreakpoint = mobileBreakpoint;
this.scrollBarWidth = scrollBarWidth;
this.thresholds = thresholds;
this.init();
}
init() {
/* istanbul ignore if */
if (typeof window === 'undefined') return;
window.addEventListener('resize', this.onResize.bind(this), {
passive: true
});
this.update();
}
onResize() {
clearTimeout(this.resizeTimeout); // Added debounce to match what
// v-resize used to do but was
// removed due to a memory leak
// https://github.com/vuetifyjs/vuetify/pull/2997
this.resizeTimeout = window.setTimeout(this.update.bind(this), 200);
}
/* eslint-disable-next-line max-statements */
update() {
const height = this.getClientHeight();
const width = this.getClientWidth();
const xs = width < this.thresholds.xs;
const sm = width < this.thresholds.sm && !xs;
const md = width < this.thresholds.md - this.scrollBarWidth && !(sm || xs);
const lg = width < this.thresholds.lg - this.scrollBarWidth && !(md || sm || xs);
const xl = width >= this.thresholds.lg - this.scrollBarWidth;
this.height = height;
this.width = width;
this.xs = xs;
this.sm = sm;
this.md = md;
this.lg = lg;
this.xl = xl;
this.xsOnly = xs;
this.smOnly = sm;
this.smAndDown = (xs || sm) && !(md || lg || xl);
this.smAndUp = !xs && (sm || md || lg || xl);
this.mdOnly = md;
this.mdAndDown = (xs || sm || md) && !(lg || xl);
this.mdAndUp = !(xs || sm) && (md || lg || xl);
this.lgOnly = lg;
this.lgAndDown = (xs || sm || md || lg) && !xl;
this.lgAndUp = !(xs || sm || md) && (lg || xl);
this.xlOnly = xl;
switch (true) {
case xs:
this.name = 'xs';
break;
case sm:
this.name = 'sm';
break;
case md:
this.name = 'md';
break;
case lg:
this.name = 'lg';
break;
default:
this.name = 'xl';
break;
}
if (typeof this.mobileBreakpoint === 'number') {
this.mobile = width < parseInt(this.mobileBreakpoint, 10);
return;
}
const breakpoints = {
xs: 0,
sm: 1,
md: 2,
lg: 3,
xl: 4
};
const current = breakpoints[this.name];
const max = breakpoints[this.mobileBreakpoint];
this.mobile = current <= max;
} // Cross-browser support as described in:
// https://stackoverflow.com/questions/1248081
getClientWidth() {
/* istanbul ignore if */
if (typeof document === 'undefined') return 0; // SSR
return Math.max(document.documentElement.clientWidth, window.innerWidth || 0);
}
getClientHeight() {
/* istanbul ignore if */
if (typeof document === 'undefined') return 0; // SSR
return Math.max(document.documentElement.clientHeight, window.innerHeight || 0);
}
}
Breakpoint.property = 'breakpoint';
//# sourceMappingURL=index.js.map
File diff suppressed because one or more lines are too long
-27
View File
@@ -1,27 +0,0 @@
// linear
export const linear = t => t; // accelerating from zero velocity
export const easeInQuad = t => t ** 2; // decelerating to zero velocity
export const easeOutQuad = t => t * (2 - t); // acceleration until halfway, then deceleration
export const easeInOutQuad = t => t < 0.5 ? 2 * t ** 2 : -1 + (4 - 2 * t) * t; // accelerating from zero velocity
export const easeInCubic = t => t ** 3; // decelerating to zero velocity
export const easeOutCubic = t => --t ** 3 + 1; // acceleration until halfway, then deceleration
export const easeInOutCubic = t => t < 0.5 ? 4 * t ** 3 : (t - 1) * (2 * t - 2) * (2 * t - 2) + 1; // accelerating from zero velocity
export const easeInQuart = t => t ** 4; // decelerating to zero velocity
export const easeOutQuart = t => 1 - --t ** 4; // acceleration until halfway, then deceleration
export const easeInOutQuart = t => t < 0.5 ? 8 * t * t * t * t : 1 - 8 * --t * t * t * t; // accelerating from zero velocity
export const easeInQuint = t => t ** 5; // decelerating to zero velocity
export const easeOutQuint = t => 1 + --t ** 5; // acceleration until halfway, then deceleration
export const easeInOutQuint = t => t < 0.5 ? 16 * t ** 5 : 1 + 16 * --t ** 5;
//# sourceMappingURL=easing-patterns.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../src/services/goto/easing-patterns.ts"],"names":[],"mappings":"AAEA;AACA,OAAO,MAAM,MAAM,GAAI,CAAD,IAAe,CAA9B,C,CACP;;AACA,OAAO,MAAM,UAAU,GAAI,CAAD,IAAe,CAAC,IAAI,CAAvC,C,CACP;;AACA,OAAO,MAAM,WAAW,GAAI,CAAD,IAAe,CAAC,IAAI,IAAI,CAAR,CAApC,C,CACP;;AACA,OAAO,MAAM,aAAa,GAAI,CAAD,IAAgB,CAAC,GAAG,GAAJ,GAAU,IAAI,CAAC,IAAI,CAAnB,GAAuB,CAAC,CAAD,GAAK,CAAC,IAAI,IAAI,CAAT,IAAc,CAAhF,C,CACP;;AACA,OAAO,MAAM,WAAW,GAAI,CAAD,IAAe,CAAC,IAAI,CAAxC,C,CACP;;AACA,OAAO,MAAM,YAAY,GAAI,CAAD,IAAe,EAAE,CAAF,IAAO,CAAP,GAAW,CAA/C,C,CACP;;AACA,OAAO,MAAM,cAAc,GAAI,CAAD,IAAe,CAAC,GAAG,GAAJ,GAAU,IAAI,CAAC,IAAI,CAAnB,GAAuB,CAAC,CAAC,GAAG,CAAL,KAAW,IAAI,CAAJ,GAAQ,CAAnB,KAAyB,IAAI,CAAJ,GAAQ,CAAjC,IAAsC,CAAnG,C,CACP;;AACA,OAAO,MAAM,WAAW,GAAI,CAAD,IAAe,CAAC,IAAI,CAAxC,C,CACP;;AACA,OAAO,MAAM,YAAY,GAAI,CAAD,IAAe,IAAI,EAAE,CAAF,IAAO,CAA/C,C,CACP;;AACA,OAAO,MAAM,cAAc,GAAI,CAAD,IAAgB,CAAC,GAAG,GAAJ,GAAU,IAAI,CAAJ,GAAQ,CAAR,GAAY,CAAZ,GAAgB,CAA1B,GAA8B,IAAI,IAAI,EAAE,CAAN,GAAU,CAAV,GAAc,CAAd,GAAkB,CAA3F,C,CACP;;AACA,OAAO,MAAM,WAAW,GAAI,CAAD,IAAe,CAAC,IAAI,CAAxC,C,CACP;;AACA,OAAO,MAAM,YAAY,GAAI,CAAD,IAAe,IAAI,EAAE,CAAF,IAAO,CAA/C,C,CACP;;AACA,OAAO,MAAM,cAAc,GAAI,CAAD,IAAe,CAAC,GAAG,GAAJ,GAAU,KAAK,CAAC,IAAI,CAApB,GAAwB,IAAI,KAAK,EAAE,CAAF,IAAO,CAA9E","sourcesContent":["export type EasingFunction = (t: number) => number\n\n// linear\nexport const linear = (t: number) => t\n// accelerating from zero velocity\nexport const easeInQuad = (t: number) => t ** 2\n// decelerating to zero velocity\nexport const easeOutQuad = (t: number) => t * (2 - t)\n// acceleration until halfway, then deceleration\nexport const easeInOutQuad = (t: number) => (t < 0.5 ? 2 * t ** 2 : -1 + (4 - 2 * t) * t)\n// accelerating from zero velocity\nexport const easeInCubic = (t: number) => t ** 3\n// decelerating to zero velocity\nexport const easeOutCubic = (t: number) => --t ** 3 + 1\n// acceleration until halfway, then deceleration\nexport const easeInOutCubic = (t: number) => t < 0.5 ? 4 * t ** 3 : (t - 1) * (2 * t - 2) * (2 * t - 2) + 1\n// accelerating from zero velocity\nexport const easeInQuart = (t: number) => t ** 4\n// decelerating to zero velocity\nexport const easeOutQuart = (t: number) => 1 - --t ** 4\n// acceleration until halfway, then deceleration\nexport const easeInOutQuart = (t: number) => (t < 0.5 ? 8 * t * t * t * t : 1 - 8 * --t * t * t * t)\n// accelerating from zero velocity\nexport const easeInQuint = (t: number) => t ** 5\n// decelerating to zero velocity\nexport const easeOutQuint = (t: number) => 1 + --t ** 5\n// acceleration until halfway, then deceleration\nexport const easeInOutQuint = (t: number) => t < 0.5 ? 16 * t ** 5 : 1 + 16 * --t ** 5\n"],"sourceRoot":"","file":"easing-patterns.js"}
-75
View File
@@ -1,75 +0,0 @@
// Extensions
import { Service } from '../service'; // Utilities
import * as easingPatterns from './easing-patterns';
import { getContainer, getOffset } from './util';
export default function goTo(_target, _settings = {}) {
const settings = {
container: document.scrollingElement || document.body || document.documentElement,
duration: 500,
offset: 0,
easing: 'easeInOutCubic',
appOffset: true,
..._settings
};
const container = getContainer(settings.container);
/* istanbul ignore else */
if (settings.appOffset && goTo.framework.application) {
const isDrawer = container.classList.contains('v-navigation-drawer');
const isClipped = container.classList.contains('v-navigation-drawer--clipped');
const {
bar,
top
} = goTo.framework.application;
settings.offset += bar;
/* istanbul ignore else */
if (!isDrawer || isClipped) settings.offset += top;
}
const startTime = performance.now();
let targetLocation;
if (typeof _target === 'number') {
targetLocation = getOffset(_target) - settings.offset;
} else {
targetLocation = getOffset(_target) - getOffset(container) - settings.offset;
}
const startLocation = container.scrollTop;
if (targetLocation === startLocation) return Promise.resolve(targetLocation);
const ease = typeof settings.easing === 'function' ? settings.easing : easingPatterns[settings.easing];
/* istanbul ignore else */
if (!ease) throw new TypeError(`Easing function "${settings.easing}" not found.`); // Cannot be tested properly in jsdom
// tslint:disable-next-line:promise-must-complete
/* istanbul ignore next */
return new Promise(resolve => requestAnimationFrame(function step(currentTime) {
const timeElapsed = currentTime - startTime;
const progress = Math.abs(settings.duration ? Math.min(timeElapsed / settings.duration, 1) : 1);
container.scrollTop = Math.floor(startLocation + (targetLocation - startLocation) * ease(progress));
const clientHeight = container === document.body ? document.documentElement.clientHeight : container.clientHeight;
if (progress === 1 || clientHeight + container.scrollTop === container.scrollHeight) {
return resolve(targetLocation);
}
requestAnimationFrame(step);
}));
}
goTo.framework = {};
goTo.init = () => {};
export class Goto extends Service {
constructor() {
super();
return goTo;
}
}
Goto.property = 'goTo';
//# sourceMappingURL=index.js.map
File diff suppressed because one or more lines are too long
-43
View File
@@ -1,43 +0,0 @@
// Return target's cumulative offset from the top
export function getOffset(target) {
if (typeof target === 'number') {
return target;
}
let el = $(target);
if (!el) {
throw typeof target === 'string' ? new Error(`Target element "${target}" not found.`) : new TypeError(`Target must be a Number/Selector/HTMLElement/VueComponent, received ${type(target)} instead.`);
}
let totalOffset = 0;
while (el) {
totalOffset += el.offsetTop;
el = el.offsetParent;
}
return totalOffset;
}
export function getContainer(container) {
const el = $(container);
if (el) return el;
throw typeof container === 'string' ? new Error(`Container element "${container}" not found.`) : new TypeError(`Container must be a Selector/HTMLElement/VueComponent, received ${type(container)} instead.`);
}
function type(el) {
return el == null ? el : el.constructor.name;
}
function $(el) {
if (typeof el === 'string') {
return document.querySelector(el);
} else if (el && el._isVue) {
return el.$el;
} else if (el instanceof HTMLElement) {
return el;
} else {
return null;
}
}
//# sourceMappingURL=util.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../src/services/goto/util.ts"],"names":[],"mappings":"AAEA;AACA,OAAM,SAAU,SAAV,CAAqB,MAArB,EAAgC;AACpC,MAAI,OAAO,MAAP,KAAkB,QAAtB,EAAgC;AAC9B,WAAO,MAAP;AACD;;AAED,MAAI,EAAE,GAAG,CAAC,CAAC,MAAD,CAAV;;AACA,MAAI,CAAC,EAAL,EAAS;AACP,UAAM,OAAO,MAAP,KAAkB,QAAlB,GACF,IAAI,KAAJ,CAAU,mBAAmB,MAAM,cAAnC,CADE,GAEF,IAAI,SAAJ,CAAc,uEAAuE,IAAI,CAAC,MAAD,CAAQ,WAAjG,CAFJ;AAGD;;AAED,MAAI,WAAW,GAAG,CAAlB;;AACA,SAAO,EAAP,EAAW;AACT,IAAA,WAAW,IAAI,EAAE,CAAC,SAAlB;AACA,IAAA,EAAE,GAAG,EAAE,CAAC,YAAR;AACD;;AAED,SAAO,WAAP;AACD;AAED,OAAM,SAAU,YAAV,CAAwB,SAAxB,EAAsC;AAC1C,QAAM,EAAE,GAAG,CAAC,CAAC,SAAD,CAAZ;AAEA,MAAI,EAAJ,EAAQ,OAAO,EAAP;AAER,QAAM,OAAO,SAAP,KAAqB,QAArB,GACF,IAAI,KAAJ,CAAU,sBAAsB,SAAS,cAAzC,CADE,GAEF,IAAI,SAAJ,CAAc,mEAAmE,IAAI,CAAC,SAAD,CAAW,WAAhG,CAFJ;AAGD;;AAED,SAAS,IAAT,CAAe,EAAf,EAAsB;AACpB,SAAO,EAAE,IAAI,IAAN,GAAa,EAAb,GAAkB,EAAE,CAAC,WAAH,CAAe,IAAxC;AACD;;AAED,SAAS,CAAT,CAAY,EAAZ,EAAmB;AACjB,MAAI,OAAO,EAAP,KAAc,QAAlB,EAA4B;AAC1B,WAAO,QAAQ,CAAC,aAAT,CAAoC,EAApC,CAAP;AACD,GAFD,MAEO,IAAI,EAAE,IAAI,EAAE,CAAC,MAAb,EAAqB;AAC1B,WAAQ,EAAU,CAAC,GAAnB;AACD,GAFM,MAEA,IAAI,EAAE,YAAY,WAAlB,EAA+B;AACpC,WAAO,EAAP;AACD,GAFM,MAEA;AACL,WAAO,IAAP;AACD;AACF","sourcesContent":["import Vue from 'vue'\n\n// Return target's cumulative offset from the top\nexport function getOffset (target: any): number {\n if (typeof target === 'number') {\n return target\n }\n\n let el = $(target)\n if (!el) {\n throw typeof target === 'string'\n ? new Error(`Target element \"${target}\" not found.`)\n : new TypeError(`Target must be a Number/Selector/HTMLElement/VueComponent, received ${type(target)} instead.`)\n }\n\n let totalOffset = 0\n while (el) {\n totalOffset += el.offsetTop\n el = el.offsetParent as HTMLElement\n }\n\n return totalOffset\n}\n\nexport function getContainer (container: any): HTMLElement {\n const el = $(container)\n\n if (el) return el\n\n throw typeof container === 'string'\n ? new Error(`Container element \"${container}\" not found.`)\n : new TypeError(`Container must be a Selector/HTMLElement/VueComponent, received ${type(container)} instead.`)\n}\n\nfunction type (el: any) {\n return el == null ? el : el.constructor.name\n}\n\nfunction $ (el: any): HTMLElement | null {\n if (typeof el === 'string') {\n return document.querySelector<HTMLElement>(el)\n } else if (el && el._isVue) {\n return (el as Vue).$el as HTMLElement\n } else if (el instanceof HTMLElement) {\n return el\n } else {\n return null\n }\n}\n"],"sourceRoot":"","file":"util.js"}
-20
View File
@@ -1,20 +0,0 @@
// Extensions
import { Service } from '../service'; // Utilities
import { mergeDeep } from '../../util/helpers'; // Presets
import presets from './presets';
export class Icons extends Service {
constructor(preset) {
super();
const {
iconfont,
values
} = preset[Icons.property];
this.iconfont = iconfont;
this.values = mergeDeep(presets[iconfont], values);
}
}
Icons.property = 'icons';
//# sourceMappingURL=index.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../src/services/icons/index.ts"],"names":[],"mappings":"AAAA;AACA,SAAS,OAAT,QAAwB,YAAxB,C,CAEA;;AACA,SAAS,SAAT,QAA0B,oBAA1B,C,CAMA;;AACA,OAAO,OAAP,MAAoB,WAApB;AAEA,OAAM,MAAO,KAAP,SAAqB,OAArB,CAA4B;AAOhC,EAAA,WAAA,CAAa,MAAb,EAAkC;AAChC;AAEA,UAAM;AACJ,MAAA,QADI;AAEJ,MAAA;AAFI,QAGF,MAAM,CAAC,KAAK,CAAC,QAAP,CAHV;AAKA,SAAK,QAAL,GAAgB,QAAhB;AACA,SAAK,MAAL,GAAc,SAAS,CACrB,OAAO,CAAC,QAAD,CADc,EAErB,MAFqB,CAAvB;AAID;;AApB+B;AACzB,KAAA,CAAA,QAAA,GAAoB,OAApB","sourcesContent":["// Extensions\nimport { Service } from '../service'\n\n// Utilities\nimport { mergeDeep } from '../../util/helpers'\n\n// Types\nimport { VuetifyPreset } from 'vuetify/types/services/presets'\nimport { Icons as IIcons } from 'vuetify/types/services/icons'\n\n// Presets\nimport presets from './presets'\n\nexport class Icons extends Service implements IIcons {\n static property: 'icons' = 'icons'\n\n public iconfont: IIcons['iconfont']\n\n public values: IIcons['values']\n\n constructor (preset: VuetifyPreset) {\n super()\n\n const {\n iconfont,\n values,\n } = preset[Icons.property]\n\n this.iconfont = iconfont\n this.values = mergeDeep(\n presets[iconfont],\n values\n ) as IIcons['values']\n }\n}\n"],"sourceRoot":"","file":"index.js"}
-17
View File
@@ -1,17 +0,0 @@
import icons from './fa';
export function convertToComponentDeclarations(component, iconSet) {
const result = {};
for (const key in iconSet) {
result[key] = {
component,
props: {
icon: iconSet[key].split(' fa-')
}
};
}
return result;
}
export default convertToComponentDeclarations('font-awesome-icon', icons);
//# sourceMappingURL=fa-svg.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../../src/services/icons/presets/fa-svg.ts"],"names":[],"mappings":"AAEA,OAAO,KAAP,MAAkB,MAAlB;AAEA,OAAM,SAAU,8BAAV,CACJ,SADI,EAEJ,OAFI,EAEiB;AAErB,QAAM,MAAM,GAA0B,EAAtC;;AAEA,OAAK,MAAM,GAAX,IAAkB,OAAlB,EAA2B;AACzB,IAAA,MAAM,CAAC,GAAD,CAAN,GAAc;AACZ,MAAA,SADY;AAEZ,MAAA,KAAK,EAAE;AACL,QAAA,IAAI,EAAG,OAAO,CAAC,GAAD,CAAP,CAAwB,KAAxB,CAA8B,MAA9B;AADF;AAFK,KAAd;AAMD;;AAED,SAAO,MAAP;AACD;AAED,eAAe,8BAA8B,CAAC,mBAAD,EAAsB,KAAtB,CAA7C","sourcesContent":["import { VuetifyIcons } from 'vuetify/types/services/icons'\nimport { Component } from 'vue'\nimport icons from './fa'\n\nexport function convertToComponentDeclarations (\n component: Component | string,\n iconSet: VuetifyIcons,\n) {\n const result: Partial<VuetifyIcons> = {}\n\n for (const key in iconSet) {\n result[key] = {\n component,\n props: {\n icon: (iconSet[key] as string).split(' fa-'),\n },\n }\n }\n\n return result as VuetifyIcons\n}\n\nexport default convertToComponentDeclarations('font-awesome-icon', icons)\n"],"sourceRoot":"","file":"fa-svg.js"}
-37
View File
@@ -1,37 +0,0 @@
const icons = {
complete: 'fas fa-check',
cancel: 'fas fa-times-circle',
close: 'fas fa-times',
delete: 'fas fa-times-circle',
clear: 'fas fa-times-circle',
success: 'fas fa-check-circle',
info: 'fas fa-info-circle',
warning: 'fas fa-exclamation',
error: 'fas fa-exclamation-triangle',
prev: 'fas fa-chevron-left',
next: 'fas fa-chevron-right',
checkboxOn: 'fas fa-check-square',
checkboxOff: 'far fa-square',
checkboxIndeterminate: 'fas fa-minus-square',
delimiter: 'fas fa-circle',
sort: 'fas fa-sort-up',
expand: 'fas fa-chevron-down',
menu: 'fas fa-bars',
subgroup: 'fas fa-caret-down',
dropdown: 'fas fa-caret-down',
radioOn: 'far fa-dot-circle',
radioOff: 'far fa-circle',
edit: 'fas fa-edit',
ratingEmpty: 'far fa-star',
ratingFull: 'fas fa-star',
ratingHalf: 'fas fa-star-half',
loading: 'fas fa-sync',
first: 'fas fa-step-backward',
last: 'fas fa-step-forward',
unfold: 'fas fa-arrows-alt-v',
file: 'fas fa-paperclip',
plus: 'fas fa-plus',
minus: 'fas fa-minus'
};
export default icons;
//# sourceMappingURL=fa.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../../src/services/icons/presets/fa.ts"],"names":[],"mappings":"AAEA,MAAM,KAAK,GAAiB;AAC1B,EAAA,QAAQ,EAAE,cADgB;AAE1B,EAAA,MAAM,EAAE,qBAFkB;AAG1B,EAAA,KAAK,EAAE,cAHmB;AAI1B,EAAA,MAAM,EAAE,qBAJkB;AAK1B,EAAA,KAAK,EAAE,qBALmB;AAM1B,EAAA,OAAO,EAAE,qBANiB;AAO1B,EAAA,IAAI,EAAE,oBAPoB;AAQ1B,EAAA,OAAO,EAAE,oBARiB;AAS1B,EAAA,KAAK,EAAE,6BATmB;AAU1B,EAAA,IAAI,EAAE,qBAVoB;AAW1B,EAAA,IAAI,EAAE,sBAXoB;AAY1B,EAAA,UAAU,EAAE,qBAZc;AAa1B,EAAA,WAAW,EAAE,eAba;AAc1B,EAAA,qBAAqB,EAAE,qBAdG;AAe1B,EAAA,SAAS,EAAE,eAfe;AAgB1B,EAAA,IAAI,EAAE,gBAhBoB;AAiB1B,EAAA,MAAM,EAAE,qBAjBkB;AAkB1B,EAAA,IAAI,EAAE,aAlBoB;AAmB1B,EAAA,QAAQ,EAAE,mBAnBgB;AAoB1B,EAAA,QAAQ,EAAE,mBApBgB;AAqB1B,EAAA,OAAO,EAAE,mBArBiB;AAsB1B,EAAA,QAAQ,EAAE,eAtBgB;AAuB1B,EAAA,IAAI,EAAE,aAvBoB;AAwB1B,EAAA,WAAW,EAAE,aAxBa;AAyB1B,EAAA,UAAU,EAAE,aAzBc;AA0B1B,EAAA,UAAU,EAAE,kBA1Bc;AA2B1B,EAAA,OAAO,EAAE,aA3BiB;AA4B1B,EAAA,KAAK,EAAE,sBA5BmB;AA6B1B,EAAA,IAAI,EAAE,qBA7BoB;AA8B1B,EAAA,MAAM,EAAE,qBA9BkB;AA+B1B,EAAA,IAAI,EAAE,kBA/BoB;AAgC1B,EAAA,IAAI,EAAE,aAhCoB;AAiC1B,EAAA,KAAK,EAAE;AAjCmB,CAA5B;AAoCA,eAAe,KAAf","sourcesContent":["import { VuetifyIcons } from 'vuetify/types/services/icons'\n\nconst icons: VuetifyIcons = {\n complete: 'fas fa-check',\n cancel: 'fas fa-times-circle',\n close: 'fas fa-times',\n delete: 'fas fa-times-circle', // delete (e.g. v-chip close)\n clear: 'fas fa-times-circle', // delete (e.g. v-chip close)\n success: 'fas fa-check-circle',\n info: 'fas fa-info-circle',\n warning: 'fas fa-exclamation',\n error: 'fas fa-exclamation-triangle',\n prev: 'fas fa-chevron-left',\n next: 'fas fa-chevron-right',\n checkboxOn: 'fas fa-check-square',\n checkboxOff: 'far fa-square', // note 'far'\n checkboxIndeterminate: 'fas fa-minus-square',\n delimiter: 'fas fa-circle', // for carousel\n sort: 'fas fa-sort-up',\n expand: 'fas fa-chevron-down',\n menu: 'fas fa-bars',\n subgroup: 'fas fa-caret-down',\n dropdown: 'fas fa-caret-down',\n radioOn: 'far fa-dot-circle',\n radioOff: 'far fa-circle',\n edit: 'fas fa-edit',\n ratingEmpty: 'far fa-star',\n ratingFull: 'fas fa-star',\n ratingHalf: 'fas fa-star-half',\n loading: 'fas fa-sync',\n first: 'fas fa-step-backward',\n last: 'fas fa-step-forward',\n unfold: 'fas fa-arrows-alt-v',\n file: 'fas fa-paperclip',\n plus: 'fas fa-plus',\n minus: 'fas fa-minus',\n}\n\nexport default icons\n"],"sourceRoot":"","file":"fa.js"}
-37
View File
@@ -1,37 +0,0 @@
const icons = {
complete: 'fa fa-check',
cancel: 'fa fa-times-circle',
close: 'fa fa-times',
delete: 'fa fa-times-circle',
clear: 'fa fa-times-circle',
success: 'fa fa-check-circle',
info: 'fa fa-info-circle',
warning: 'fa fa-exclamation',
error: 'fa fa-exclamation-triangle',
prev: 'fa fa-chevron-left',
next: 'fa fa-chevron-right',
checkboxOn: 'fa fa-check-square',
checkboxOff: 'fa fa-square-o',
checkboxIndeterminate: 'fa fa-minus-square',
delimiter: 'fa fa-circle',
sort: 'fa fa-sort-up',
expand: 'fa fa-chevron-down',
menu: 'fa fa-bars',
subgroup: 'fa fa-caret-down',
dropdown: 'fa fa-caret-down',
radioOn: 'fa fa-dot-circle-o',
radioOff: 'fa fa-circle-o',
edit: 'fa fa-pencil',
ratingEmpty: 'fa fa-star-o',
ratingFull: 'fa fa-star',
ratingHalf: 'fa fa-star-half-o',
loading: 'fa fa-refresh',
first: 'fa fa-step-backward',
last: 'fa fa-step-forward',
unfold: 'fa fa-angle-double-down',
file: 'fa fa-paperclip',
plus: 'fa fa-plus',
minus: 'fa fa-minus'
};
export default icons;
//# sourceMappingURL=fa4.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../../src/services/icons/presets/fa4.ts"],"names":[],"mappings":"AAEA,MAAM,KAAK,GAAiB;AAC1B,EAAA,QAAQ,EAAE,aADgB;AAE1B,EAAA,MAAM,EAAE,oBAFkB;AAG1B,EAAA,KAAK,EAAE,aAHmB;AAI1B,EAAA,MAAM,EAAE,oBAJkB;AAK1B,EAAA,KAAK,EAAE,oBALmB;AAM1B,EAAA,OAAO,EAAE,oBANiB;AAO1B,EAAA,IAAI,EAAE,mBAPoB;AAQ1B,EAAA,OAAO,EAAE,mBARiB;AAS1B,EAAA,KAAK,EAAE,4BATmB;AAU1B,EAAA,IAAI,EAAE,oBAVoB;AAW1B,EAAA,IAAI,EAAE,qBAXoB;AAY1B,EAAA,UAAU,EAAE,oBAZc;AAa1B,EAAA,WAAW,EAAE,gBAba;AAc1B,EAAA,qBAAqB,EAAE,oBAdG;AAe1B,EAAA,SAAS,EAAE,cAfe;AAgB1B,EAAA,IAAI,EAAE,eAhBoB;AAiB1B,EAAA,MAAM,EAAE,oBAjBkB;AAkB1B,EAAA,IAAI,EAAE,YAlBoB;AAmB1B,EAAA,QAAQ,EAAE,kBAnBgB;AAoB1B,EAAA,QAAQ,EAAE,kBApBgB;AAqB1B,EAAA,OAAO,EAAE,oBArBiB;AAsB1B,EAAA,QAAQ,EAAE,gBAtBgB;AAuB1B,EAAA,IAAI,EAAE,cAvBoB;AAwB1B,EAAA,WAAW,EAAE,cAxBa;AAyB1B,EAAA,UAAU,EAAE,YAzBc;AA0B1B,EAAA,UAAU,EAAE,mBA1Bc;AA2B1B,EAAA,OAAO,EAAE,eA3BiB;AA4B1B,EAAA,KAAK,EAAE,qBA5BmB;AA6B1B,EAAA,IAAI,EAAE,oBA7BoB;AA8B1B,EAAA,MAAM,EAAE,yBA9BkB;AA+B1B,EAAA,IAAI,EAAE,iBA/BoB;AAgC1B,EAAA,IAAI,EAAE,YAhCoB;AAiC1B,EAAA,KAAK,EAAE;AAjCmB,CAA5B;AAoCA,eAAe,KAAf","sourcesContent":["import { VuetifyIcons } from 'vuetify/types/services/icons'\n\nconst icons: VuetifyIcons = {\n complete: 'fa fa-check',\n cancel: 'fa fa-times-circle',\n close: 'fa fa-times',\n delete: 'fa fa-times-circle', // delete (e.g. v-chip close)\n clear: 'fa fa-times-circle', // delete (e.g. v-chip close)\n success: 'fa fa-check-circle',\n info: 'fa fa-info-circle',\n warning: 'fa fa-exclamation',\n error: 'fa fa-exclamation-triangle',\n prev: 'fa fa-chevron-left',\n next: 'fa fa-chevron-right',\n checkboxOn: 'fa fa-check-square',\n checkboxOff: 'fa fa-square-o',\n checkboxIndeterminate: 'fa fa-minus-square',\n delimiter: 'fa fa-circle', // for carousel\n sort: 'fa fa-sort-up',\n expand: 'fa fa-chevron-down',\n menu: 'fa fa-bars',\n subgroup: 'fa fa-caret-down',\n dropdown: 'fa fa-caret-down',\n radioOn: 'fa fa-dot-circle-o',\n radioOff: 'fa fa-circle-o',\n edit: 'fa fa-pencil',\n ratingEmpty: 'fa fa-star-o',\n ratingFull: 'fa fa-star',\n ratingHalf: 'fa fa-star-half-o',\n loading: 'fa fa-refresh',\n first: 'fa fa-step-backward',\n last: 'fa fa-step-forward',\n unfold: 'fa fa-angle-double-down',\n file: 'fa fa-paperclip',\n plus: 'fa fa-plus',\n minus: 'fa fa-minus',\n}\n\nexport default icons\n"],"sourceRoot":"","file":"fa4.js"}
-15
View File
@@ -1,15 +0,0 @@
import mdiSvg from './mdi-svg';
import md from './md';
import mdi from './mdi';
import fa from './fa';
import fa4 from './fa4';
import faSvg from './fa-svg';
export default Object.freeze({
mdiSvg,
md,
mdi,
fa,
fa4,
faSvg
});
//# sourceMappingURL=index.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../../src/services/icons/presets/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAP,MAAmB,WAAnB;AACA,OAAO,EAAP,MAAe,MAAf;AACA,OAAO,GAAP,MAAgB,OAAhB;AACA,OAAO,EAAP,MAAe,MAAf;AACA,OAAO,GAAP,MAAgB,OAAhB;AACA,OAAO,KAAP,MAAkB,UAAlB;AAEA,eAAe,MAAM,CAAC,MAAP,CAAc;AAC3B,EAAA,MAD2B;AAE3B,EAAA,EAF2B;AAG3B,EAAA,GAH2B;AAI3B,EAAA,EAJ2B;AAK3B,EAAA,GAL2B;AAM3B,EAAA;AAN2B,CAAd,CAAf","sourcesContent":["import mdiSvg from './mdi-svg'\nimport md from './md'\nimport mdi from './mdi'\nimport fa from './fa'\nimport fa4 from './fa4'\nimport faSvg from './fa-svg'\n\nexport default Object.freeze({\n mdiSvg,\n md,\n mdi,\n fa,\n fa4,\n faSvg,\n})\n"],"sourceRoot":"","file":"index.js"}
-37
View File
@@ -1,37 +0,0 @@
const icons = {
complete: 'check',
cancel: 'cancel',
close: 'close',
delete: 'cancel',
clear: 'clear',
success: 'check_circle',
info: 'info',
warning: 'priority_high',
error: 'warning',
prev: 'chevron_left',
next: 'chevron_right',
checkboxOn: 'check_box',
checkboxOff: 'check_box_outline_blank',
checkboxIndeterminate: 'indeterminate_check_box',
delimiter: 'fiber_manual_record',
sort: 'arrow_upward',
expand: 'keyboard_arrow_down',
menu: 'menu',
subgroup: 'arrow_drop_down',
dropdown: 'arrow_drop_down',
radioOn: 'radio_button_checked',
radioOff: 'radio_button_unchecked',
edit: 'edit',
ratingEmpty: 'star_border',
ratingFull: 'star',
ratingHalf: 'star_half',
loading: 'cached',
first: 'first_page',
last: 'last_page',
unfold: 'unfold_more',
file: 'attach_file',
plus: 'add',
minus: 'remove'
};
export default icons;
//# sourceMappingURL=md.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../../src/services/icons/presets/md.ts"],"names":[],"mappings":"AAEA,MAAM,KAAK,GAAiB;AAC1B,EAAA,QAAQ,EAAE,OADgB;AAE1B,EAAA,MAAM,EAAE,QAFkB;AAG1B,EAAA,KAAK,EAAE,OAHmB;AAI1B,EAAA,MAAM,EAAE,QAJkB;AAK1B,EAAA,KAAK,EAAE,OALmB;AAM1B,EAAA,OAAO,EAAE,cANiB;AAO1B,EAAA,IAAI,EAAE,MAPoB;AAQ1B,EAAA,OAAO,EAAE,eARiB;AAS1B,EAAA,KAAK,EAAE,SATmB;AAU1B,EAAA,IAAI,EAAE,cAVoB;AAW1B,EAAA,IAAI,EAAE,eAXoB;AAY1B,EAAA,UAAU,EAAE,WAZc;AAa1B,EAAA,WAAW,EAAE,yBAba;AAc1B,EAAA,qBAAqB,EAAE,yBAdG;AAe1B,EAAA,SAAS,EAAE,qBAfe;AAgB1B,EAAA,IAAI,EAAE,cAhBoB;AAiB1B,EAAA,MAAM,EAAE,qBAjBkB;AAkB1B,EAAA,IAAI,EAAE,MAlBoB;AAmB1B,EAAA,QAAQ,EAAE,iBAnBgB;AAoB1B,EAAA,QAAQ,EAAE,iBApBgB;AAqB1B,EAAA,OAAO,EAAE,sBArBiB;AAsB1B,EAAA,QAAQ,EAAE,wBAtBgB;AAuB1B,EAAA,IAAI,EAAE,MAvBoB;AAwB1B,EAAA,WAAW,EAAE,aAxBa;AAyB1B,EAAA,UAAU,EAAE,MAzBc;AA0B1B,EAAA,UAAU,EAAE,WA1Bc;AA2B1B,EAAA,OAAO,EAAE,QA3BiB;AA4B1B,EAAA,KAAK,EAAE,YA5BmB;AA6B1B,EAAA,IAAI,EAAE,WA7BoB;AA8B1B,EAAA,MAAM,EAAE,aA9BkB;AA+B1B,EAAA,IAAI,EAAE,aA/BoB;AAgC1B,EAAA,IAAI,EAAE,KAhCoB;AAiC1B,EAAA,KAAK,EAAE;AAjCmB,CAA5B;AAoCA,eAAe,KAAf","sourcesContent":["import { VuetifyIcons } from 'vuetify/types/services/icons'\n\nconst icons: VuetifyIcons = {\n complete: 'check',\n cancel: 'cancel',\n close: 'close',\n delete: 'cancel', // delete (e.g. v-chip close)\n clear: 'clear',\n success: 'check_circle',\n info: 'info',\n warning: 'priority_high',\n error: 'warning',\n prev: 'chevron_left',\n next: 'chevron_right',\n checkboxOn: 'check_box',\n checkboxOff: 'check_box_outline_blank',\n checkboxIndeterminate: 'indeterminate_check_box',\n delimiter: 'fiber_manual_record', // for carousel\n sort: 'arrow_upward',\n expand: 'keyboard_arrow_down',\n menu: 'menu',\n subgroup: 'arrow_drop_down',\n dropdown: 'arrow_drop_down',\n radioOn: 'radio_button_checked',\n radioOff: 'radio_button_unchecked',\n edit: 'edit',\n ratingEmpty: 'star_border',\n ratingFull: 'star',\n ratingHalf: 'star_half',\n loading: 'cached',\n first: 'first_page',\n last: 'last_page',\n unfold: 'unfold_more',\n file: 'attach_file',\n plus: 'add',\n minus: 'remove',\n}\n\nexport default icons\n"],"sourceRoot":"","file":"md.js"}
-37
View File
@@ -1,37 +0,0 @@
const icons = {
complete: 'M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z',
cancel: 'M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z',
close: 'M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z',
delete: 'M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z',
clear: 'M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z',
success: 'M12,2C17.52,2 22,6.48 22,12C22,17.52 17.52,22 12,22C6.48,22 2,17.52 2,12C2,6.48 6.48,2 12,2M11,16.5L18,9.5L16.59,8.09L11,13.67L7.91,10.59L6.5,12L11,16.5Z',
info: 'M13,9H11V7H13M13,17H11V11H13M12,2C6.48,2 2,6.48 2,12C2,17.52 6.48,22 12,22C17.52,22 22,17.52 22,12C22,6.48 17.52,2 12,2Z',
warning: 'M11,4.5H13V15.5H11V4.5M13,17.5V19.5H11V17.5H13Z',
error: 'M13,14H11V10H13M13,18H11V16H13M1,21H23L12,2L1,21Z',
prev: 'M15.41,16.58L10.83,12L15.41,7.41L14,6L8,12L14,18L15.41,16.58Z',
next: 'M8.59,16.58L13.17,12L8.59,7.41L10,6L16,12L10,18L8.59,16.58Z',
checkboxOn: 'M10,17L5,12L6.41,10.58L10,14.17L17.59,6.58L19,8M19,3H5C3.89,3 3,3.89 3,5V19C3,20.1 3.9,21 5,21H19C20.1,21 21,20.1 21,19V5C21,3.89 20.1,3 19,3Z',
checkboxOff: 'M19,3H5C3.89,3 3,3.89 3,5V19C3,20.1 3.9,21 5,21H19C20.1,21 21,20.1 21,19V5C21,3.89 20.1,3 19,3M19,5V19H5V5H19Z',
checkboxIndeterminate: 'M17,13H7V11H17M19,3H5C3.89,3 3,3.89 3,5V19C3,20.1 3.9,21 5,21H19C20.1,21 21,20.1 21,19V5C21,3.89 20.1,3 19,3Z',
delimiter: 'M12,2C6.48,2 2,6.48 2,12C2,17.52 6.48,22 12,22C17.52,22 22,17.52 22,12C22,6.48 17.52,2 12,2Z',
sort: 'M13,20H11V8L5.5,13.5L4.08,12.08L12,4.16L19.92,12.08L18.5,13.5L13,8V20Z',
expand: 'M7.41,8.58L12,13.17L16.59,8.58L18,10L12,16L6,10L7.41,8.58Z',
menu: 'M3,6H21V8H3V6M3,11H21V13H3V11M3,16H21V18H3V16Z',
subgroup: 'M7,10L12,15L17,10H7Z',
dropdown: 'M7,10L12,15L17,10H7Z',
radioOn: 'M12,20C7.58,20 4,16.42 4,12C4,7.58 7.58,4 12,4C16.42,4 20,7.58 20,12C20,16.42 16.42,20 12,20M12,2C6.48,2 2,6.48 2,12C2,17.52 6.48,22 12,22C17.52,22 22,17.52 22,12C22,6.48 17.52,2 12,2M12,7C9.24,7 7,9.24 7,12C7,14.76 9.24,17 12,17C14.76,17 17,14.76 17,12C17,9.24 14.76,7 12,7Z',
radioOff: 'M12,20C7.58,20 4,16.42 4,12C4,7.58 7.58,4 12,4C16.42,4 20,7.58 20,12C20,16.42 16.42,20 12,20M12,2C6.48,2 2,6.48 2,12C2,17.52 6.48,22 12,22C17.52,22 22,17.52 22,12C22,6.48 17.52,2 12,2Z',
edit: 'M20.71,7.04C21.1,6.65 21.1,6 20.71,5.63L18.37,3.29C18,2.9 17.35,2.9 16.96,3.29L15.12,5.12L18.87,8.87M3,17.25V21H6.75L17.81,9.93L14.06,6.18L3,17.25Z',
ratingEmpty: 'M12,15.39L8.24,17.66L9.23,13.38L5.91,10.5L10.29,10.13L12,6.09L13.71,10.13L18.09,10.5L14.77,13.38L15.76,17.66M22,9.24L14.81,8.63L12,2L9.19,8.63L2,9.24L7.45,13.97L5.82,21L12,17.27L18.18,21L16.54,13.97L22,9.24Z',
ratingFull: 'M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z',
ratingHalf: 'M12,15.4V6.1L13.71,10.13L18.09,10.5L14.77,13.39L15.76,17.67M22,9.24L14.81,8.63L12,2L9.19,8.63L2,9.24L7.45,13.97L5.82,21L12,17.27L18.18,21L16.54,13.97L22,9.24Z',
loading: 'M19,8L15,12H18C18,15.31 15.31,18 12,18C11,18 10.03,17.75 9.2,17.3L7.74,18.76C8.97,19.54 10.43,20 12,20C16.42,20 20,16.42 20,12H23M6,12C6,8.69 8.69,6 12,6C13,6 13.97,6.25 14.8,6.7L16.26,5.24C15.03,4.46 13.57,4 12,4C7.58,4 4,7.58 4,12H1L5,16L9,12',
first: 'M18.41,16.59L13.82,12L18.41,7.41L17,6L11,12L17,18L18.41,16.59M6,6H8V18H6V6Z',
last: 'M5.59,7.41L10.18,12L5.59,16.59L7,18L13,12L7,6L5.59,7.41M16,6H18V18H16V6Z',
unfold: 'M12,18.17L8.83,15L7.42,16.41L12,21L16.59,16.41L15.17,15M12,5.83L15.17,9L16.58,7.59L12,3L7.41,7.59L8.83,9L12,5.83Z',
file: 'M16.5,6V17.5C16.5,19.71 14.71,21.5 12.5,21.5C10.29,21.5 8.5,19.71 8.5,17.5V5C8.5,3.62 9.62,2.5 11,2.5C12.38,2.5 13.5,3.62 13.5,5V15.5C13.5,16.05 13.05,16.5 12.5,16.5C11.95,16.5 11.5,16.05 11.5,15.5V6H10V15.5C10,16.88 11.12,18 12.5,18C13.88,18 15,16.88 15,15.5V5C15,2.79 13.21,1 11,1C8.79,1 7,2.79 7,5V17.5C7,20.54 9.46,23 12.5,23C15.54,23 18,20.54 18,17.5V6H16.5Z',
plus: 'M19,13H13V19H11V13H5V11H11V5H13V11H19V13Z',
minus: 'M19,13H5V11H19V13Z'
};
export default icons;
//# sourceMappingURL=mdi-svg.js.map
File diff suppressed because one or more lines are too long
-37
View File
@@ -1,37 +0,0 @@
const icons = {
complete: 'mdi-check',
cancel: 'mdi-close-circle',
close: 'mdi-close',
delete: 'mdi-close-circle',
clear: 'mdi-close',
success: 'mdi-check-circle',
info: 'mdi-information',
warning: 'mdi-exclamation',
error: 'mdi-alert',
prev: 'mdi-chevron-left',
next: 'mdi-chevron-right',
checkboxOn: 'mdi-checkbox-marked',
checkboxOff: 'mdi-checkbox-blank-outline',
checkboxIndeterminate: 'mdi-minus-box',
delimiter: 'mdi-circle',
sort: 'mdi-arrow-up',
expand: 'mdi-chevron-down',
menu: 'mdi-menu',
subgroup: 'mdi-menu-down',
dropdown: 'mdi-menu-down',
radioOn: 'mdi-radiobox-marked',
radioOff: 'mdi-radiobox-blank',
edit: 'mdi-pencil',
ratingEmpty: 'mdi-star-outline',
ratingFull: 'mdi-star',
ratingHalf: 'mdi-star-half',
loading: 'mdi-cached',
first: 'mdi-page-first',
last: 'mdi-page-last',
unfold: 'mdi-unfold-more-horizontal',
file: 'mdi-paperclip',
plus: 'mdi-plus',
minus: 'mdi-minus'
};
export default icons;
//# sourceMappingURL=mdi.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../../src/services/icons/presets/mdi.ts"],"names":[],"mappings":"AAEA,MAAM,KAAK,GAAiB;AAC1B,EAAA,QAAQ,EAAE,WADgB;AAE1B,EAAA,MAAM,EAAE,kBAFkB;AAG1B,EAAA,KAAK,EAAE,WAHmB;AAI1B,EAAA,MAAM,EAAE,kBAJkB;AAK1B,EAAA,KAAK,EAAE,WALmB;AAM1B,EAAA,OAAO,EAAE,kBANiB;AAO1B,EAAA,IAAI,EAAE,iBAPoB;AAQ1B,EAAA,OAAO,EAAE,iBARiB;AAS1B,EAAA,KAAK,EAAE,WATmB;AAU1B,EAAA,IAAI,EAAE,kBAVoB;AAW1B,EAAA,IAAI,EAAE,mBAXoB;AAY1B,EAAA,UAAU,EAAE,qBAZc;AAa1B,EAAA,WAAW,EAAE,4BAba;AAc1B,EAAA,qBAAqB,EAAE,eAdG;AAe1B,EAAA,SAAS,EAAE,YAfe;AAgB1B,EAAA,IAAI,EAAE,cAhBoB;AAiB1B,EAAA,MAAM,EAAE,kBAjBkB;AAkB1B,EAAA,IAAI,EAAE,UAlBoB;AAmB1B,EAAA,QAAQ,EAAE,eAnBgB;AAoB1B,EAAA,QAAQ,EAAE,eApBgB;AAqB1B,EAAA,OAAO,EAAE,qBArBiB;AAsB1B,EAAA,QAAQ,EAAE,oBAtBgB;AAuB1B,EAAA,IAAI,EAAE,YAvBoB;AAwB1B,EAAA,WAAW,EAAE,kBAxBa;AAyB1B,EAAA,UAAU,EAAE,UAzBc;AA0B1B,EAAA,UAAU,EAAE,eA1Bc;AA2B1B,EAAA,OAAO,EAAE,YA3BiB;AA4B1B,EAAA,KAAK,EAAE,gBA5BmB;AA6B1B,EAAA,IAAI,EAAE,eA7BoB;AA8B1B,EAAA,MAAM,EAAE,4BA9BkB;AA+B1B,EAAA,IAAI,EAAE,eA/BoB;AAgC1B,EAAA,IAAI,EAAE,UAhCoB;AAiC1B,EAAA,KAAK,EAAE;AAjCmB,CAA5B;AAoCA,eAAe,KAAf","sourcesContent":["import { VuetifyIcons } from 'vuetify/types/services/icons'\n\nconst icons: VuetifyIcons = {\n complete: 'mdi-check',\n cancel: 'mdi-close-circle',\n close: 'mdi-close',\n delete: 'mdi-close-circle', // delete (e.g. v-chip close)\n clear: 'mdi-close',\n success: 'mdi-check-circle',\n info: 'mdi-information',\n warning: 'mdi-exclamation',\n error: 'mdi-alert',\n prev: 'mdi-chevron-left',\n next: 'mdi-chevron-right',\n checkboxOn: 'mdi-checkbox-marked',\n checkboxOff: 'mdi-checkbox-blank-outline',\n checkboxIndeterminate: 'mdi-minus-box',\n delimiter: 'mdi-circle', // for carousel\n sort: 'mdi-arrow-up',\n expand: 'mdi-chevron-down',\n menu: 'mdi-menu',\n subgroup: 'mdi-menu-down',\n dropdown: 'mdi-menu-down',\n radioOn: 'mdi-radiobox-marked',\n radioOff: 'mdi-radiobox-blank',\n edit: 'mdi-pencil',\n ratingEmpty: 'mdi-star-outline',\n ratingFull: 'mdi-star',\n ratingHalf: 'mdi-star-half',\n loading: 'mdi-cached',\n first: 'mdi-page-first',\n last: 'mdi-page-last',\n unfold: 'mdi-unfold-more-horizontal',\n file: 'mdi-paperclip',\n plus: 'mdi-plus',\n minus: 'mdi-minus',\n}\n\nexport default icons\n"],"sourceRoot":"","file":"mdi.js"}
-8
View File
@@ -1,8 +0,0 @@
export * from './application';
export * from './breakpoint';
export * from './goto';
export * from './icons';
export * from './lang';
export * from './presets';
export * from './theme';
//# sourceMappingURL=index.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../src/services/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAd;AACA,cAAc,cAAd;AACA,cAAc,QAAd;AACA,cAAc,SAAd;AACA,cAAc,QAAd;AACA,cAAc,WAAd;AACA,cAAc,SAAd","sourcesContent":["export * from './application'\nexport * from './breakpoint'\nexport * from './goto'\nexport * from './icons'\nexport * from './lang'\nexport * from './presets'\nexport * from './theme'\n"],"sourceRoot":"","file":"index.js"}
-64
View File
@@ -1,64 +0,0 @@
// Extensions
import { Service } from '../service'; // Utilities
import { getObjectValueByPath } from '../../util/helpers';
import { consoleError, consoleWarn } from '../../util/console';
const LANG_PREFIX = '$vuetify.';
const fallback = Symbol('Lang fallback');
function getTranslation(locale, key, usingDefault = false, defaultLocale) {
const shortKey = key.replace(LANG_PREFIX, '');
let translation = getObjectValueByPath(locale, shortKey, fallback);
if (translation === fallback) {
if (usingDefault) {
consoleError(`Translation key "${shortKey}" not found in fallback`);
translation = key;
} else {
consoleWarn(`Translation key "${shortKey}" not found, falling back to default`);
translation = getTranslation(defaultLocale, key, true, defaultLocale);
}
}
return translation;
}
export class Lang extends Service {
constructor(preset) {
super();
this.defaultLocale = 'en';
const {
current,
locales,
t
} = preset[Lang.property];
this.current = current;
this.locales = locales;
this.translator = t || this.defaultTranslator;
}
currentLocale(key) {
const translation = this.locales[this.current];
const defaultLocale = this.locales[this.defaultLocale];
return getTranslation(translation, key, false, defaultLocale);
}
t(key, ...params) {
if (!key.startsWith(LANG_PREFIX)) return this.replace(key, params);
return this.translator(key, ...params);
}
defaultTranslator(key, ...params) {
return this.replace(this.currentLocale(key), params);
}
replace(str, params) {
return str.replace(/\{(\d+)\}/g, (match, index) => {
/* istanbul ignore next */
return String(params[+index]);
});
}
}
Lang.property = 'lang';
//# sourceMappingURL=index.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../src/services/lang/index.ts"],"names":[],"mappings":"AAAA;AACA,SAAS,OAAT,QAAwB,YAAxB,C,CAEA;;AACA,SAAS,oBAAT,QAAqC,oBAArC;AACA,SAAS,YAAT,EAAuB,WAAvB,QAA0C,oBAA1C;AASA,MAAM,WAAW,GAAG,WAApB;AACA,MAAM,QAAQ,GAAG,MAAM,CAAC,eAAD,CAAvB;;AAEA,SAAS,cAAT,CACE,MADF,EAEE,GAFF,EAGE,YAAY,GAAG,KAHjB,EAIE,aAJF,EAI8B;AAE5B,QAAM,QAAQ,GAAG,GAAG,CAAC,OAAJ,CAAY,WAAZ,EAAyB,EAAzB,CAAjB;AACA,MAAI,WAAW,GAAG,oBAAoB,CAAC,MAAD,EAAS,QAAT,EAAmB,QAAnB,CAAtC;;AAEA,MAAI,WAAW,KAAK,QAApB,EAA8B;AAC5B,QAAI,YAAJ,EAAkB;AAChB,MAAA,YAAY,CAAC,oBAAoB,QAAQ,yBAA7B,CAAZ;AACA,MAAA,WAAW,GAAG,GAAd;AACD,KAHD,MAGO;AACL,MAAA,WAAW,CAAC,oBAAoB,QAAQ,sCAA7B,CAAX;AACA,MAAA,WAAW,GAAG,cAAc,CAAC,aAAD,EAAgB,GAAhB,EAAqB,IAArB,EAA2B,aAA3B,CAA5B;AACD;AACF;;AAED,SAAO,WAAP;AACD;;AAED,OAAM,MAAO,IAAP,SAAoB,OAApB,CAA2B;AAW/B,EAAA,WAAA,CAAa,MAAb,EAAkC;AAChC;AAPK,SAAA,aAAA,GAAgB,IAAhB;AASL,UAAM;AACJ,MAAA,OADI;AAEJ,MAAA,OAFI;AAGJ,MAAA;AAHI,QAIF,MAAM,CAAC,IAAI,CAAC,QAAN,CAJV;AAMA,SAAK,OAAL,GAAe,OAAf;AACA,SAAK,OAAL,GAAe,OAAf;AACA,SAAK,UAAL,GAAkB,CAAC,IAAI,KAAK,iBAA5B;AACD;;AAEM,EAAA,aAAa,CAAE,GAAF,EAAa;AAC/B,UAAM,WAAW,GAAG,KAAK,OAAL,CAAa,KAAK,OAAlB,CAApB;AACA,UAAM,aAAa,GAAG,KAAK,OAAL,CAAa,KAAK,aAAlB,CAAtB;AAEA,WAAO,cAAc,CAAC,WAAD,EAAc,GAAd,EAAmB,KAAnB,EAA0B,aAA1B,CAArB;AACD;;AAEM,EAAA,CAAC,CAAE,GAAF,EAAe,GAAG,MAAlB,EAA+B;AACrC,QAAI,CAAC,GAAG,CAAC,UAAJ,CAAe,WAAf,CAAL,EAAkC,OAAO,KAAK,OAAL,CAAa,GAAb,EAAkB,MAAlB,CAAP;AAElC,WAAO,KAAK,UAAL,CAAgB,GAAhB,EAAqB,GAAG,MAAxB,CAAP;AACD;;AAEO,EAAA,iBAAiB,CAAE,GAAF,EAAe,GAAG,MAAlB,EAA+B;AACtD,WAAO,KAAK,OAAL,CAAa,KAAK,aAAL,CAAmB,GAAnB,CAAb,EAAsC,MAAtC,CAAP;AACD;;AAEO,EAAA,OAAO,CAAE,GAAF,EAAe,MAAf,EAA4B;AACzC,WAAO,GAAG,CAAC,OAAJ,CAAY,YAAZ,EAA0B,CAAC,KAAD,EAAgB,KAAhB,KAAiC;AAChE;AACA,aAAO,MAAM,CAAC,MAAM,CAAC,CAAC,KAAF,CAAP,CAAb;AACD,KAHM,CAAP;AAID;;AA/C8B;AACxB,IAAA,CAAA,QAAA,GAAmB,MAAnB","sourcesContent":["// Extensions\nimport { Service } from '../service'\n\n// Utilities\nimport { getObjectValueByPath } from '../../util/helpers'\nimport { consoleError, consoleWarn } from '../../util/console'\n\n// Types\nimport { VuetifyPreset } from 'vuetify/types/services/presets'\nimport {\n VuetifyLocale,\n Lang as ILang,\n} from 'vuetify/types/services/lang'\n\nconst LANG_PREFIX = '$vuetify.'\nconst fallback = Symbol('Lang fallback')\n\nfunction getTranslation (\n locale: VuetifyLocale,\n key: string,\n usingDefault = false,\n defaultLocale: VuetifyLocale\n): string {\n const shortKey = key.replace(LANG_PREFIX, '')\n let translation = getObjectValueByPath(locale, shortKey, fallback) as string | typeof fallback\n\n if (translation === fallback) {\n if (usingDefault) {\n consoleError(`Translation key \"${shortKey}\" not found in fallback`)\n translation = key\n } else {\n consoleWarn(`Translation key \"${shortKey}\" not found, falling back to default`)\n translation = getTranslation(defaultLocale, key, true, defaultLocale)\n }\n }\n\n return translation\n}\n\nexport class Lang extends Service implements ILang {\n static property: 'lang' = 'lang'\n\n public current: ILang['current']\n\n public defaultLocale = 'en'\n\n public locales: ILang['locales']\n\n private translator: ILang['t']\n\n constructor (preset: VuetifyPreset) {\n super()\n\n const {\n current,\n locales,\n t,\n } = preset[Lang.property]\n\n this.current = current\n this.locales = locales\n this.translator = t || this.defaultTranslator\n }\n\n public currentLocale (key: string) {\n const translation = this.locales[this.current]\n const defaultLocale = this.locales[this.defaultLocale]\n\n return getTranslation(translation, key, false, defaultLocale)\n }\n\n public t (key: string, ...params: any[]) {\n if (!key.startsWith(LANG_PREFIX)) return this.replace(key, params)\n\n return this.translator(key, ...params)\n }\n\n private defaultTranslator (key: string, ...params: any[]) {\n return this.replace(this.currentLocale(key), params)\n }\n\n private replace (str: string, params: any[]) {\n return str.replace(/\\{(\\d+)\\}/g, (match: string, index: string) => {\n /* istanbul ignore next */\n return String(params[+index])\n })\n }\n}\n"],"sourceRoot":"","file":"index.js"}
-31
View File
@@ -1,31 +0,0 @@
// Preset
import { preset as Preset } from '../../presets/default'; // Utilities
import { consoleWarn } from '../../util/console';
import { mergeDeep } from '../../util/helpers';
import { Service } from '../service';
export class Presets extends Service {
constructor(parentPreset, parent) {
super(); // The default preset
const defaultPreset = mergeDeep({}, Preset); // The user provided preset
const {
userPreset
} = parent; // The user provided global preset
const {
preset: globalPreset = {},
...preset
} = userPreset;
if (globalPreset.preset != null) {
consoleWarn('Global presets do not support the **preset** option, it can be safely omitted');
}
parent.preset = mergeDeep(mergeDeep(defaultPreset, globalPreset), preset);
}
}
Presets.property = 'presets';
//# sourceMappingURL=index.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../src/services/presets/index.ts"],"names":[],"mappings":"AAAA;AACA,SAAS,MAAM,IAAI,MAAnB,QAAiC,uBAAjC,C,CAEA;;AACA,SAAS,WAAT,QAA4B,oBAA5B;AACA,SAAS,SAAT,QAA0B,oBAA1B;AAIA,SAAS,OAAT,QAAwB,YAAxB;AAMA,OAAM,MAAO,OAAP,SAAuB,OAAvB,CAA8B;AAGlC,EAAA,WAAA,CACE,YADF,EAEE,MAFF,EAEwC;AAEtC,YAFsC,CAItC;;AACA,UAAM,aAAa,GAAG,SAAS,CAAC,EAAD,EAAK,MAAL,CAA/B,CALsC,CAMtC;;AACA,UAAM;AAAE,MAAA;AAAF,QAAiB,MAAvB,CAPsC,CAQtC;;AACA,UAAM;AACJ,MAAA,MAAM,EAAE,YAAY,GAAG,EADnB;AAEJ,SAAG;AAFC,QAGF,UAHJ;;AAKA,QAAI,YAAY,CAAC,MAAb,IAAuB,IAA3B,EAAiC;AAC/B,MAAA,WAAW,CAAC,+EAAD,CAAX;AACD;;AAED,IAAA,MAAM,CAAC,MAAP,GAAgB,SAAS,CACvB,SAAS,CAAC,aAAD,EAAgB,YAAhB,CADc,EAEvB,MAFuB,CAAzB;AAID;;AA3BiC;AAC3B,OAAA,CAAA,QAAA,GAAsB,SAAtB","sourcesContent":["// Preset\nimport { preset as Preset } from '../../presets/default'\n\n// Utilities\nimport { consoleWarn } from '../../util/console'\nimport { mergeDeep } from '../../util/helpers'\n\n// Types\nimport Framework from 'vuetify/types'\nimport { Service } from '../service'\nimport {\n UserVuetifyPreset,\n VuetifyPreset,\n} from 'vuetify/types/services/presets'\n\nexport class Presets extends Service {\n static property: 'presets' = 'presets'\n\n constructor (\n parentPreset: Partial<UserVuetifyPreset>,\n parent: InstanceType<typeof Framework>,\n ) {\n super()\n\n // The default preset\n const defaultPreset = mergeDeep({}, Preset)\n // The user provided preset\n const { userPreset } = parent\n // The user provided global preset\n const {\n preset: globalPreset = {},\n ...preset\n } = userPreset\n\n if (globalPreset.preset != null) {\n consoleWarn('Global presets do not support the **preset** option, it can be safely omitted')\n }\n\n parent.preset = mergeDeep(\n mergeDeep(defaultPreset, globalPreset),\n preset\n ) as VuetifyPreset\n }\n}\n"],"sourceRoot":"","file":"index.js"}
-9
View File
@@ -1,9 +0,0 @@
export class Service {
constructor() {
this.framework = {};
}
init(root, ssrContext) {}
}
//# sourceMappingURL=index.js.map
-1
View File
@@ -1 +0,0 @@
{"version":3,"sources":["../../../src/services/service/index.ts"],"names":[],"mappings":"AAMA,OAAM,MAAO,OAAP,CAAc;AAApB,EAAA,WAAA,GAAA;AACE,SAAA,SAAA,GAAY,EAAZ;AAGD;;AADC,EAAA,IAAI,CAAE,IAAF,EAAa,UAAb,EAAgC,CAAI;;AAHtB","sourcesContent":["// Contracts\nimport { VuetifyServiceContract } from 'vuetify/types/services/index'\n\n// Types\nimport Vue from 'vue'\n\nexport class Service implements VuetifyServiceContract {\n framework = {}\n\n init (root: Vue, ssrContext?: object) {}\n}\n"],"sourceRoot":"","file":"index.js"}
-258
View File
@@ -1,258 +0,0 @@
/* eslint-disable no-multi-spaces */
// Extensions
import { Service } from '../service'; // Utilities
import * as ThemeUtils from './utils';
import { getNestedValue } from '../../util/helpers'; // Types
import Vue from 'vue';
export class Theme extends Service {
constructor(preset) {
super();
this.disabled = false;
this.isDark = null;
this.vueInstance = null;
this.vueMeta = null;
const {
dark,
disable,
options,
themes
} = preset[Theme.property];
this.dark = Boolean(dark);
this.defaults = this.themes = themes;
this.options = options;
if (disable) {
this.disabled = true;
return;
}
this.themes = {
dark: this.fillVariant(themes.dark, true),
light: this.fillVariant(themes.light, false)
};
} // When setting css, check for element
// and apply new values
set css(val) {
if (this.vueMeta) {
if (this.isVueMeta23) {
this.applyVueMeta23();
}
return;
}
this.checkOrCreateStyleElement() && (this.styleEl.innerHTML = val);
}
set dark(val) {
const oldDark = this.isDark;
this.isDark = val; // Only apply theme after dark
// has already been set before
oldDark != null && this.applyTheme();
}
get dark() {
return Boolean(this.isDark);
} // Apply current theme default
// only called on client side
applyTheme() {
if (this.disabled) return this.clearCss();
this.css = this.generatedStyles;
}
clearCss() {
this.css = '';
} // Initialize theme for SSR and SPA
// Attach to ssrContext head or
// apply new theme to document
init(root, ssrContext) {
if (this.disabled) return;
/* istanbul ignore else */
if (root.$meta) {
this.initVueMeta(root);
} else if (ssrContext) {
this.initSSR(ssrContext);
}
this.initTheme();
} // Allows for you to set target theme
setTheme(theme, value) {
this.themes[theme] = Object.assign(this.themes[theme], value);
this.applyTheme();
} // Reset theme defaults
resetThemes() {
this.themes.light = Object.assign({}, this.defaults.light);
this.themes.dark = Object.assign({}, this.defaults.dark);
this.applyTheme();
} // Check for existence of style element
checkOrCreateStyleElement() {
this.styleEl = document.getElementById('vuetify-theme-stylesheet');
/* istanbul ignore next */
if (this.styleEl) return true;
this.genStyleElement(); // If doesn't have it, create it
return Boolean(this.styleEl);
}
fillVariant(theme = {}, dark) {
const defaultTheme = this.themes[dark ? 'dark' : 'light'];
return Object.assign({}, defaultTheme, theme);
} // Generate the style element
// if applicable
genStyleElement() {
/* istanbul ignore if */
if (typeof document === 'undefined') return;
/* istanbul ignore next */
this.styleEl = document.createElement('style');
this.styleEl.type = 'text/css';
this.styleEl.id = 'vuetify-theme-stylesheet';
if (this.options.cspNonce) {
this.styleEl.setAttribute('nonce', this.options.cspNonce);
}
document.head.appendChild(this.styleEl);
}
initVueMeta(root) {
this.vueMeta = root.$meta();
if (this.isVueMeta23) {
// vue-meta needs to apply after mounted()
root.$nextTick(() => {
this.applyVueMeta23();
});
return;
}
const metaKeyName = typeof this.vueMeta.getOptions === 'function' ? this.vueMeta.getOptions().keyName : 'metaInfo';
const metaInfo = root.$options[metaKeyName] || {};
root.$options[metaKeyName] = () => {
metaInfo.style = metaInfo.style || [];
const vuetifyStylesheet = metaInfo.style.find(s => s.id === 'vuetify-theme-stylesheet');
if (!vuetifyStylesheet) {
metaInfo.style.push({
cssText: this.generatedStyles,
type: 'text/css',
id: 'vuetify-theme-stylesheet',
nonce: (this.options || {}).cspNonce
});
} else {
vuetifyStylesheet.cssText = this.generatedStyles;
}
return metaInfo;
};
}
applyVueMeta23() {
const {
set
} = this.vueMeta.addApp('vuetify');
set({
style: [{
cssText: this.generatedStyles,
type: 'text/css',
id: 'vuetify-theme-stylesheet',
nonce: this.options.cspNonce
}]
});
}
initSSR(ssrContext) {
// SSR
const nonce = this.options.cspNonce ? ` nonce="${this.options.cspNonce}"` : '';
ssrContext.head = ssrContext.head || '';
ssrContext.head += `<style type="text/css" id="vuetify-theme-stylesheet"${nonce}>${this.generatedStyles}</style>`;
}
initTheme() {
// Only watch for reactivity on client side
if (typeof document === 'undefined') return; // If we get here somehow, ensure
// existing instance is removed
if (this.vueInstance) this.vueInstance.$destroy(); // Use Vue instance to track reactivity
// TODO: Update to use RFC if merged
// https://github.com/vuejs/rfcs/blob/advanced-reactivity-api/active-rfcs/0000-advanced-reactivity-api.md
this.vueInstance = new Vue({
data: {
themes: this.themes
},
watch: {
themes: {
immediate: true,
deep: true,
handler: () => this.applyTheme()
}
}
});
}
get currentTheme() {
const target = this.dark ? 'dark' : 'light';
return this.themes[target];
}
get generatedStyles() {
const theme = this.parsedTheme;
/* istanbul ignore next */
const options = this.options || {};
let css;
if (options.themeCache != null) {
css = options.themeCache.get(theme);
/* istanbul ignore if */
if (css != null) return css;
}
css = ThemeUtils.genStyles(theme, options.customProperties);
if (options.minifyTheme != null) {
css = options.minifyTheme(css);
}
if (options.themeCache != null) {
options.themeCache.set(theme, css);
}
return css;
}
get parsedTheme() {
return ThemeUtils.parse(this.currentTheme || {}, undefined, getNestedValue(this.options, ['variations'], true));
} // Is using v2.3 of vue-meta
// https://github.com/nuxt/vue-meta/releases/tag/v2.3.0
get isVueMeta23() {
return typeof this.vueMeta.addApp === 'function';
}
}
Theme.property = 'theme';
//# sourceMappingURL=index.js.map
File diff suppressed because one or more lines are too long
-136
View File
@@ -1,136 +0,0 @@
import { colorToInt, intToHex, colorToHex } from '../../util/colorUtils';
import * as sRGB from '../../util/color/transformSRGB';
import * as LAB from '../../util/color/transformCIELAB';
export function parse(theme, isItem = false, variations = true) {
const {
anchor,
...variant
} = theme;
const colors = Object.keys(variant);
const parsedTheme = {};
for (let i = 0; i < colors.length; ++i) {
const name = colors[i];
const value = theme[name];
if (value == null) continue;
if (!variations) {
parsedTheme[name] = {
base: intToHex(colorToInt(value))
};
} else if (isItem) {
/* istanbul ignore else */
if (name === 'base' || name.startsWith('lighten') || name.startsWith('darken')) {
parsedTheme[name] = colorToHex(value);
}
} else if (typeof value === 'object') {
parsedTheme[name] = parse(value, true, variations);
} else {
parsedTheme[name] = genVariations(name, colorToInt(value));
}
}
if (!isItem) {
parsedTheme.anchor = anchor || parsedTheme.base || parsedTheme.primary.base;
}
return parsedTheme;
}
/**
* Generate the CSS for a base color (.primary)
*/
const genBaseColor = (name, value) => {
return `
.v-application .${name} {
background-color: ${value} !important;
border-color: ${value} !important;
}
.v-application .${name}--text {
color: ${value} !important;
caret-color: ${value} !important;
}`;
};
/**
* Generate the CSS for a variant color (.primary.darken-2)
*/
const genVariantColor = (name, variant, value) => {
const [type, n] = variant.split(/(\d)/, 2);
return `
.v-application .${name}.${type}-${n} {
background-color: ${value} !important;
border-color: ${value} !important;
}
.v-application .${name}--text.text--${type}-${n} {
color: ${value} !important;
caret-color: ${value} !important;
}`;
};
const genColorVariableName = (name, variant = 'base') => `--v-${name}-${variant}`;
const genColorVariable = (name, variant = 'base') => `var(${genColorVariableName(name, variant)})`;
export function genStyles(theme, cssVar = false) {
const {
anchor,
...variant
} = theme;
const colors = Object.keys(variant);
if (!colors.length) return '';
let variablesCss = '';
let css = '';
const aColor = cssVar ? genColorVariable('anchor') : anchor;
css += `.v-application a { color: ${aColor}; }`;
cssVar && (variablesCss += ` ${genColorVariableName('anchor')}: ${anchor};\n`);
for (let i = 0; i < colors.length; ++i) {
const name = colors[i];
const value = theme[name];
css += genBaseColor(name, cssVar ? genColorVariable(name) : value.base);
cssVar && (variablesCss += ` ${genColorVariableName(name)}: ${value.base};\n`);
const variants = Object.keys(value);
for (let i = 0; i < variants.length; ++i) {
const variant = variants[i];
const variantValue = value[variant];
if (variant === 'base') continue;
css += genVariantColor(name, variant, cssVar ? genColorVariable(name, variant) : variantValue);
cssVar && (variablesCss += ` ${genColorVariableName(name, variant)}: ${variantValue};\n`);
}
}
if (cssVar) {
variablesCss = `:root {\n${variablesCss}}\n\n`;
}
return variablesCss + css;
}
export function genVariations(name, value) {
const values = {
base: intToHex(value)
};
for (let i = 5; i > 0; --i) {
values[`lighten${i}`] = intToHex(lighten(value, i));
}
for (let i = 1; i <= 4; ++i) {
values[`darken${i}`] = intToHex(darken(value, i));
}
return values;
}
export function lighten(value, amount) {
const lab = LAB.fromXYZ(sRGB.toXYZ(value));
lab[0] = lab[0] + amount * 10;
return sRGB.fromXYZ(LAB.toXYZ(lab));
}
export function darken(value, amount) {
const lab = LAB.fromXYZ(sRGB.toXYZ(value));
lab[0] = lab[0] - amount * 10;
return sRGB.fromXYZ(LAB.toXYZ(lab));
}
//# sourceMappingURL=utils.js.map
File diff suppressed because one or more lines are too long