Tracking de l'application VApp (IHM du jeu)

This commit is contained in:
2025-05-11 18:04:12 +02:00
commit 89e9db9b62
17763 changed files with 3718499 additions and 0 deletions

View File

@ -0,0 +1,49 @@
.v-icon {
--v-icon-size-multiplier: 1;
align-items: center;
display: inline-flex;
font-feature-settings: "liga";
height: 1em;
justify-content: center;
letter-spacing: normal;
line-height: 1;
position: relative;
text-indent: 0;
text-align: center;
user-select: none;
vertical-align: middle;
width: 1em;
min-width: 1em;
}
.v-icon--clickable {
cursor: pointer;
}
.v-icon--size-x-small {
font-size: calc(var(--v-icon-size-multiplier) * 1em);
}
.v-icon--size-small {
font-size: calc(var(--v-icon-size-multiplier) * 1.25em);
}
.v-icon--size-default {
font-size: calc(var(--v-icon-size-multiplier) * 1.5em);
}
.v-icon--size-large {
font-size: calc(var(--v-icon-size-multiplier) * 1.75em);
}
.v-icon--size-x-large {
font-size: calc(var(--v-icon-size-multiplier) * 2em);
}
.v-icon__svg {
fill: currentColor;
width: 100%;
height: 100%;
}
.v-icon--start {
margin-inline-end: 8px;
}
.v-icon--end {
margin-inline-start: 8px;
}

View File

@ -0,0 +1,75 @@
import { createVNode as _createVNode } from "vue";
// Styles
import "./VIcon.css";
// Composables
import { useTextColor } from "../../composables/color.mjs";
import { makeComponentProps } from "../../composables/component.mjs";
import { IconValue, useIcon } from "../../composables/icons.mjs";
import { makeSizeProps, useSize } from "../../composables/size.mjs";
import { makeTagProps } from "../../composables/tag.mjs";
import { makeThemeProps, provideTheme } from "../../composables/theme.mjs"; // Utilities
import { computed, ref, Text, toRef } from 'vue';
import { convertToUnit, flattenFragments, genericComponent, propsFactory, useRender } from "../../util/index.mjs";
export const makeVIconProps = propsFactory({
color: String,
start: Boolean,
end: Boolean,
icon: IconValue,
...makeComponentProps(),
...makeSizeProps(),
...makeTagProps({
tag: 'i'
}),
...makeThemeProps()
}, 'VIcon');
export const VIcon = genericComponent()({
name: 'VIcon',
props: makeVIconProps(),
setup(props, _ref) {
let {
attrs,
slots
} = _ref;
const slotIcon = ref();
const {
themeClasses
} = provideTheme(props);
const {
iconData
} = useIcon(computed(() => slotIcon.value || props.icon));
const {
sizeClasses
} = useSize(props);
const {
textColorClasses,
textColorStyles
} = useTextColor(toRef(props, 'color'));
useRender(() => {
const slotValue = slots.default?.();
if (slotValue) {
slotIcon.value = flattenFragments(slotValue).filter(node => node.type === Text && node.children && typeof node.children === 'string')[0]?.children;
}
return _createVNode(iconData.value.component, {
"tag": props.tag,
"icon": iconData.value.icon,
"class": ['v-icon', 'notranslate', themeClasses.value, sizeClasses.value, textColorClasses.value, {
'v-icon--clickable': !!attrs.onClick,
'v-icon--start': props.start,
'v-icon--end': props.end
}, props.class],
"style": [!sizeClasses.value ? {
fontSize: convertToUnit(props.size),
height: convertToUnit(props.size),
width: convertToUnit(props.size)
} : undefined, textColorStyles.value, props.style],
"role": attrs.onClick ? 'button' : undefined,
"aria-hidden": !attrs.onClick
}, {
default: () => [slotValue]
});
});
return {};
}
});
//# sourceMappingURL=VIcon.mjs.map

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,38 @@
@use 'sass:map'
@use '../../styles/settings'
@use './variables' as *
.v-icon
--v-icon-size-multiplier: 1
align-items: center
display: inline-flex
font-feature-settings: 'liga'
height: $icon-size
justify-content: center
letter-spacing: $icon-letter-spacing
line-height: $icon-line-height
position: relative
text-indent: $icon-text-indent
text-align: center
user-select: none
vertical-align: $icon-vertical-align
width: $icon-size
min-width: $icon-size
&--clickable
cursor: pointer
@each $name in settings.$sizes
&--size-#{$name}
font-size: calc(var(--v-icon-size-multiplier) * #{map.get($icon-sizes, $name)})
.v-icon__svg
fill: currentColor
width: 100%
height: 100%
.v-icon--start
margin-inline-end: $icon-margin-start
.v-icon--end
margin-inline-start: $icon-margin-end

View File

@ -0,0 +1,26 @@
@use 'sass:map';
@use '../../styles/settings';
@use '../../styles/tools';
// VIcon
$icon-left-margin-left: map.get(settings.$grid-gutters, 'md') !default;
$icon-letter-spacing: normal !default;
$icon-line-height: 1 !default;
$icon-margin-end: map.get(settings.$grid-gutters, 'md') !default;
$icon-margin-start: map.get(settings.$grid-gutters, 'md') !default;
$icon-size: 1em !default;
$icon-text-indent: 0 !default;
$icon-vertical-align: middle !default;
// Lists
$icon-sizes: () !default;
$icon-sizes: tools.map-deep-merge(
(
'x-small': 1em,
'small': 1.25em,
'default': 1.5em,
'large': 1.75em,
'x-large': 2em,
),
$icon-sizes
);

View File

@ -0,0 +1,452 @@
import * as vue from 'vue';
import { ComponentPropsOptions, ExtractPropTypes, PropType, JSXComponent } from 'vue';
interface FilterPropsOptions<PropsOptions extends Readonly<ComponentPropsOptions>, Props = ExtractPropTypes<PropsOptions>> {
filterProps<T extends Partial<Props>, U extends Exclude<keyof Props, Exclude<keyof Props, keyof T>>>(props: T): Partial<Pick<T, U>>;
}
type IconValue = string | (string | [path: string, opacity: number])[] | JSXComponent;
declare const IconValue: PropType<IconValue>;
declare const VComponentIcon: {
new (...args: any[]): vue.CreateComponentPublicInstance<{
tag: string;
} & {
icon?: IconValue | undefined;
} & {
$children?: vue.VNodeChild | (() => vue.VNodeChild) | {
default?: (() => vue.VNodeChild) | undefined;
};
'v-slots'?: {
default?: false | (() => vue.VNodeChild) | undefined;
} | undefined;
} & {
"v-slot:default"?: false | (() => vue.VNodeChild) | undefined;
}, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, Record<string, any>, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & {
tag: string;
} & {
icon?: IconValue | undefined;
} & {
$children?: vue.VNodeChild | (() => vue.VNodeChild) | {
default?: (() => vue.VNodeChild) | undefined;
};
'v-slots'?: {
default?: false | (() => vue.VNodeChild) | undefined;
} | undefined;
} & {
"v-slot:default"?: false | (() => vue.VNodeChild) | undefined;
}, {}, true, {}, vue.SlotsType<Partial<{
default: () => vue.VNode<vue.RendererNode, vue.RendererElement, {
[key: string]: any;
}>[];
}>>, {
P: {};
B: {};
D: {};
C: {};
M: {};
Defaults: {};
}, {
tag: string;
} & {
icon?: IconValue | undefined;
} & {
$children?: vue.VNodeChild | (() => vue.VNodeChild) | {
default?: (() => vue.VNodeChild) | undefined;
};
'v-slots'?: {
default?: false | (() => vue.VNodeChild) | undefined;
} | undefined;
} & {
"v-slot:default"?: false | (() => vue.VNodeChild) | undefined;
}, () => JSX.Element, {}, {}, {}, {}>;
__isFragment?: undefined;
__isTeleport?: undefined;
__isSuspense?: undefined;
} & vue.ComponentOptionsBase<{
tag: string;
} & {
icon?: IconValue | undefined;
} & {
$children?: vue.VNodeChild | (() => vue.VNodeChild) | {
default?: (() => vue.VNodeChild) | undefined;
};
'v-slots'?: {
default?: false | (() => vue.VNodeChild) | undefined;
} | undefined;
} & {
"v-slot:default"?: false | (() => vue.VNodeChild) | undefined;
}, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, Record<string, any>, string, {}, {}, string, vue.SlotsType<Partial<{
default: () => vue.VNode<vue.RendererNode, vue.RendererElement, {
[key: string]: any;
}>[];
}>>> & vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & FilterPropsOptions<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}, vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>;
type VComponentIcon = InstanceType<typeof VComponentIcon>;
declare const VSvgIcon: {
new (...args: any[]): vue.CreateComponentPublicInstance<Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, {}, true, {}, {}, {
P: {};
B: {};
D: {};
C: {};
M: {};
Defaults: {};
}, Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, () => JSX.Element, {}, {}, {}, {}>;
__isFragment?: undefined;
__isTeleport?: undefined;
__isSuspense?: undefined;
} & vue.ComponentOptionsBase<Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, {}, {}, string, {}> & vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & FilterPropsOptions<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}, vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>;
type VSvgIcon = InstanceType<typeof VSvgIcon>;
declare const VLigatureIcon: {
new (...args: any[]): vue.CreateComponentPublicInstance<Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, {}, true, {}, {}, {
P: {};
B: {};
D: {};
C: {};
M: {};
Defaults: {};
}, Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, () => JSX.Element, {}, {}, {}, {}>;
__isFragment?: undefined;
__isTeleport?: undefined;
__isSuspense?: undefined;
} & vue.ComponentOptionsBase<Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, {}, {}, string, {}> & vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & FilterPropsOptions<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}, vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>;
type VLigatureIcon = InstanceType<typeof VLigatureIcon>;
declare const VClassIcon: {
new (...args: any[]): vue.CreateComponentPublicInstance<Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, {}, true, {}, {}, {
P: {};
B: {};
D: {};
C: {};
M: {};
Defaults: {};
}, Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, () => JSX.Element, {}, {}, {}, {}>;
__isFragment?: undefined;
__isTeleport?: undefined;
__isSuspense?: undefined;
} & vue.ComponentOptionsBase<Readonly<vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>, () => JSX.Element, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, string, {}, {}, string, {}> & vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & FilterPropsOptions<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}, vue.ExtractPropTypes<{
icon: {
type: PropType<IconValue>;
};
tag: {
type: StringConstructor;
required: true;
};
}>>;
type VClassIcon = InstanceType<typeof VClassIcon>;
declare const VIcon: {
new (...args: any[]): vue.CreateComponentPublicInstance<{
end: boolean;
start: boolean;
style: vue.StyleValue;
size: string | number;
tag: string;
} & {
color?: string | undefined;
class?: any;
icon?: IconValue | undefined;
theme?: string | undefined;
} & {
$children?: vue.VNodeChild | (() => vue.VNodeChild) | {
default?: (() => vue.VNodeChild) | undefined;
};
'v-slots'?: {
default?: false | (() => vue.VNodeChild) | undefined;
} | undefined;
} & {
"v-slot:default"?: false | (() => vue.VNodeChild) | undefined;
}, {}, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, Record<string, any>, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & {
end: boolean;
start: boolean;
style: vue.StyleValue;
size: string | number;
tag: string;
} & {
color?: string | undefined;
class?: any;
icon?: IconValue | undefined;
theme?: string | undefined;
} & {
$children?: vue.VNodeChild | (() => vue.VNodeChild) | {
default?: (() => vue.VNodeChild) | undefined;
};
'v-slots'?: {
default?: false | (() => vue.VNodeChild) | undefined;
} | undefined;
} & {
"v-slot:default"?: false | (() => vue.VNodeChild) | undefined;
}, {
end: boolean;
start: boolean;
style: vue.StyleValue;
size: string | number;
tag: string;
}, true, {}, vue.SlotsType<Partial<{
default: () => vue.VNode<vue.RendererNode, vue.RendererElement, {
[key: string]: any;
}>[];
}>>, {
P: {};
B: {};
D: {};
C: {};
M: {};
Defaults: {};
}, {
end: boolean;
start: boolean;
style: vue.StyleValue;
size: string | number;
tag: string;
} & {
color?: string | undefined;
class?: any;
icon?: IconValue | undefined;
theme?: string | undefined;
} & {
$children?: vue.VNodeChild | (() => vue.VNodeChild) | {
default?: (() => vue.VNodeChild) | undefined;
};
'v-slots'?: {
default?: false | (() => vue.VNodeChild) | undefined;
} | undefined;
} & {
"v-slot:default"?: false | (() => vue.VNodeChild) | undefined;
}, {}, {}, {}, {}, {
end: boolean;
start: boolean;
style: vue.StyleValue;
size: string | number;
tag: string;
}>;
__isFragment?: undefined;
__isTeleport?: undefined;
__isSuspense?: undefined;
} & vue.ComponentOptionsBase<{
end: boolean;
start: boolean;
style: vue.StyleValue;
size: string | number;
tag: string;
} & {
color?: string | undefined;
class?: any;
icon?: IconValue | undefined;
theme?: string | undefined;
} & {
$children?: vue.VNodeChild | (() => vue.VNodeChild) | {
default?: (() => vue.VNodeChild) | undefined;
};
'v-slots'?: {
default?: false | (() => vue.VNodeChild) | undefined;
} | undefined;
} & {
"v-slot:default"?: false | (() => vue.VNodeChild) | undefined;
}, {}, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, Record<string, any>, string, {
end: boolean;
start: boolean;
style: vue.StyleValue;
size: string | number;
tag: string;
}, {}, string, vue.SlotsType<Partial<{
default: () => vue.VNode<vue.RendererNode, vue.RendererElement, {
[key: string]: any;
}>[];
}>>> & vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & FilterPropsOptions<{
theme: StringConstructor;
tag: Omit<{
type: StringConstructor;
default: string;
}, "type" | "default"> & {
type: vue.PropType<string>;
default: string;
};
size: {
type: (StringConstructor | NumberConstructor)[];
default: string;
};
class: vue.PropType<any>;
style: {
type: vue.PropType<vue.StyleValue>;
default: null;
};
color: StringConstructor;
start: BooleanConstructor;
end: BooleanConstructor;
icon: vue.PropType<IconValue>;
}, vue.ExtractPropTypes<{
theme: StringConstructor;
tag: Omit<{
type: StringConstructor;
default: string;
}, "type" | "default"> & {
type: vue.PropType<string>;
default: string;
};
size: {
type: (StringConstructor | NumberConstructor)[];
default: string;
};
class: vue.PropType<any>;
style: {
type: vue.PropType<vue.StyleValue>;
default: null;
};
color: StringConstructor;
start: BooleanConstructor;
end: BooleanConstructor;
icon: vue.PropType<IconValue>;
}>>;
type VIcon = InstanceType<typeof VIcon>;
export { VClassIcon, VComponentIcon, VIcon, VLigatureIcon, VSvgIcon };

View File

@ -0,0 +1,3 @@
export { VIcon } from "./VIcon.mjs";
export { VComponentIcon, VSvgIcon, VLigatureIcon, VClassIcon } from "../../composables/icons.mjs";
//# sourceMappingURL=index.mjs.map

View File

@ -0,0 +1 @@
{"version":3,"file":"index.mjs","names":["VIcon","VComponentIcon","VSvgIcon","VLigatureIcon","VClassIcon"],"sources":["../../../src/components/VIcon/index.ts"],"sourcesContent":["export { VIcon } from './VIcon'\nexport { VComponentIcon, VSvgIcon, VLigatureIcon, VClassIcon } from '@/composables/icons'\n"],"mappings":"SAASA,KAAK;AAAA,SACLC,cAAc,EAAEC,QAAQ,EAAEC,aAAa,EAAEC,UAAU"}