Skip to content

Commit

Permalink
feat: auto import
Browse files Browse the repository at this point in the history
  • Loading branch information
mrjackwills committed Jun 7, 2023
1 parent d1d2beb commit 41495b5
Show file tree
Hide file tree
Showing 26 changed files with 1,063 additions and 934 deletions.
5 changes: 3 additions & 2 deletions .eslintrc-auto-import.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@
"watch": true,
"watchEffect": true,
"watchPostEffect": true,
"watchSyncEffect": true
"watchSyncEffect": true,
"toValue": true
}
}
}
1 change: 1 addition & 0 deletions components.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ declare module 'vue' {
AdminDeviceRow: typeof import('./src/components/Admin/AdminDeviceRow.vue')['default']
AdminEmails: typeof import('./src/components/Admin/AdminEmails.vue')['default']
AdminInvite: typeof import('./src/components/Admin/AdminInvite.vue')['default']
AdminInvites: typeof import('./src/components/Admin/AdminInvites.vue')['default']
AdminLimits: typeof import('./src/components/Admin/AdminLimits.vue')['default']
AdminMemory: typeof import('./src/components/Admin/AdminMemory.vue')['default']
AdminUserRow: typeof import('./src/components/Admin/AdminUserRow.vue')['default']
Expand Down
1,856 changes: 991 additions & 865 deletions package-lock.json

Large diffs are not rendered by default.

26 changes: 13 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,34 +17,34 @@
"@vueuse/head": "^1.1.26",
"axios": "^1.4.0",
"hibp": "^13.0.0",
"pinia": "^2.0.36",
"pinia": "^2.1.3",
"pinia-plugin-persistedstate": "^3.1.0",
"prismjs": "^1.29.0",
"qrcode.vue": "^3.4.0",
"secure-json-parse": "^2.7.0",
"vue": "^3.3.1",
"vue-router": "^4.2.0",
"vue": "^3.3.4",
"vue-router": "^4.2.2",
"vuetify": "^3.2.4"
},
"devDependencies": {
"@mdi/js": "^7.2.96",
"@types/node": "^20.1.3",
"@types/node": "^20.2.5",
"@types/prismjs": "^1.26.0",
"@types/secure-json-parse": "^1.0.3",
"@vitejs/plugin-vue": "^4.2.2",
"@vitejs/plugin-vue": "^4.2.3",
"@vue/eslint-config-typescript": "^11.0.3",
"@vue/tsconfig": "^0.3.2",
"eslint": "^8.40.0",
"eslint-plugin-vue": "^9.12.0",
"@vue/tsconfig": "^0.4.0",
"eslint": "^8.42.0",
"eslint-plugin-vue": "^9.14.1",
"sass": "^1.62.1",
"typescript": "^5.0.4",
"unplugin-auto-import": "^0.15.3",
"typescript": "^5.1.3",
"unplugin-auto-import": "^0.16.4",
"unplugin-vue-components": "^0.25.1",
"vite": "^4.3.5",
"vite": "^4.3.9",
"vite-plugin-compression": "^0.5.1",
"vite-plugin-pwa": "^0.14.7",
"vite-plugin-pwa": "^0.16.3",
"vite-plugin-vuetify": "^1.0.2",
"vue-tsc": "^1.6.4"
"vue-tsc": "^1.6.5"
},
"buildDate": "Thu 11 2023 May 13:42:30 EDT",
"homepage": "https://github.com/mrjackwills/staticpi_vue"
Expand Down
1 change: 1 addition & 0 deletions src/auto-imports.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ declare global {
const toRaw: typeof import('vue')['toRaw']
const toRef: typeof import('vue')['toRef']
const toRefs: typeof import('vue')['toRefs']
const toValue: typeof import('vue')['toValue']
const triggerRef: typeof import('vue')['triggerRef']
const twoFAModule: typeof import('./store/twoFA')['twoFAModule']
const unref: typeof import('vue')['unref']
Expand Down
File renamed without changes.
18 changes: 9 additions & 9 deletions src/components/Buttons/ActionButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -109,17 +109,17 @@ onMounted(() => {
});
const props = withDefaults(defineProps<{
block: boolean,
color: string,
disabled: boolean,
block?: boolean,
color?: string,
disabled?: boolean,
icon?: string,
iconFirst: boolean,
monospace: boolean,
mouseOverEvents: boolean,
overrideDisabled: boolean,
iconFirst?: boolean,
monospace?: boolean,
mouseOverEvents?: boolean,
overrideDisabled?: boolean,
routerLink?: string
small: boolean,
text: string
small?: boolean,
text?: string
}>(), {
block: false,
color: 'primary',
Expand Down
2 changes: 1 addition & 1 deletion src/components/Buttons/BackButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@ const goBack = (): void => {
else router.push(FrontEndRoutes.BASE);
};
withDefaults(defineProps<{disabled: boolean}>(), { disabled: false });
withDefaults(defineProps<{disabled?: boolean}>(), { disabled: false });
</script>
10 changes: 5 additions & 5 deletions src/components/Buttons/CopyButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,11 @@ const onIntersect = (is_i: boolean, _entries: Array<IntersectionObserverEntry>,
};
const props = withDefaults(defineProps<{
color: string,
dark: boolean,
density: VBtn['$props']['density'],
disabled: boolean,
hoverMessage: string,
color?: string,
dark?: boolean,
density?: VBtn['$props']['density'],
disabled?: boolean,
hoverMessage?: string,
small?:boolean
toCopy: string,
tooltipMessage: string,
Expand Down
4 changes: 2 additions & 2 deletions src/components/Buttons/DocumentationLink.vue
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ const iconSize = computed((): string => {
const props = withDefaults(defineProps<{
section: string,
small: boolean,
xsmall: boolean,
small?: boolean,
xsmall?: boolean,
}>(), {
small: true,
xsmall: false,
Expand Down
4 changes: 2 additions & 2 deletions src/components/Buttons/FabTooltip.vue
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ const iconSize = computed(() => {
const props = withDefaults(defineProps<{
color: string,
disabled: boolean,
disabled?: boolean,
icon: string,
medium: boolean,
medium?: boolean,
tooltip_text: string
}>(), {
disabled: false,
Expand Down
2 changes: 1 addition & 1 deletion src/components/Buttons/ProUserChip.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,5 @@ const size = computed(() => {
}
});
withDefaults(defineProps<{order: string}>(), { order: '1' });
withDefaults(defineProps<{order?: string}>(), { order: '1' });
</script>
24 changes: 12 additions & 12 deletions src/components/Card/AppCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -55,21 +55,21 @@ const border = computed((): string => {
});
const props = withDefaults(defineProps<{
disabled: boolean,
flat: boolean,
hasButton: boolean,
heading: string,
disabled?: boolean,
flat?: boolean,
hasButton?: boolean,
heading?: string,
heading_justify?: VRow['$props']['justify'],
heading_class?: string,
heading_size?: string,
lg: string,
loading: boolean,
my: string,
outlined: boolean,
pad: boolean,
sm: string,
tile: boolean,
xl: string
lg?: string,
loading?: boolean,
my?: string,
outlined?: boolean,
pad?: boolean,
sm?: string,
tile?: boolean,
xl?: string
}>(), {
disabled: false,
flat: false,
Expand Down
6 changes: 3 additions & 3 deletions src/components/Card/CardHeading.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ const headingSize = computed((): string => {
});
const props = withDefaults(defineProps<{
divider: boolean,
divider?: boolean,
heading: string,
justify: VRow['$props']['justify'],
margin: string
justify?: VRow['$props']['justify'],
margin?: string
size?: string,
}>(), {
divider: false,
Expand Down
4 changes: 2 additions & 2 deletions src/components/Card/DocumentationCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<ProUserChip :class='proMargin' class='ma-1 ml-3' v-if='pro' />
</v-col>
<v-col cols='auto' class='ma-0 pa-0' order='1'>
<Subheading :heading='heading' justify='start' :id='createId' />
<SubHeading :heading='heading' justify='start' :id='createId' />
</v-col>
</v-row>
<v-divider class='mb-1' />
Expand Down Expand Up @@ -44,7 +44,7 @@ const smallText = computed((): string => {
const props = withDefaults(defineProps<{
heading: string,
pro: boolean
pro?: boolean
}>(), {
pro: false,
});
Expand Down
4 changes: 2 additions & 2 deletions src/components/Card/SubHeading.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ const headingColor = computed((): string => {
});
const props = withDefaults(defineProps<{
color: string,
color?: string,
heading: string,
heading_size?: string,
justify: VRow['$props']['justify']
justify?: VRow['$props']['justify']
}>(), {
color: 'pi',
justify: 'center',
Expand Down
2 changes: 1 addition & 1 deletion src/components/CodeBlock.vue
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ const highlighted_code = computed((): string => {
const codeIcons= [ '#ff5f56', '#ffbd2e', '#27c93f' ];
const props = withDefaults(defineProps<{code: string, filename: string, titleBar: boolean}>(), {
const props = withDefaults(defineProps<{code: string, filename?: string, titleBar?: boolean}>(), {
filename: '',
titleBar: true,
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ const toggleHidden = (): void => {
emit('hidden', hidden.value);
};
withDefaults(defineProps<{device: TDeviceInfo, show_calc: boolean}>(), {
withDefaults(defineProps<{device: TDeviceInfo, show_calc?: boolean}>(), {
show_calc: true,
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const showBorder = computed(() : string => {
});
const props = withDefaults(defineProps<{
borderRight: boolean,
borderRight?: boolean,
total: string,
unit: string,
variety: string
Expand Down
2 changes: 1 addition & 1 deletion src/components/Devices/NumberOfDevices.vue
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ const converted_total = computed((): TConvertBytes => {
return convert_bytes(totalBandwidth.value);
});
const props = withDefaults(defineProps<{rowCols: string}>(), {
const props = withDefaults(defineProps<{rowCols?: string}>(), {
rowCols: '12',
});
Expand Down
2 changes: 1 addition & 1 deletion src/components/Settings/SettingSection.vue
Original file line number Diff line number Diff line change
Expand Up @@ -62,5 +62,5 @@ const title = computed((): string => {
return smAndDown.value ? 'text-h7' : 'text-h6';
});
withDefaults(defineProps<{disabled: boolean, proOnly: boolean}>(), { disabled: false, proOnly: false });
withDefaults(defineProps<{disabled?: boolean, proOnly?: boolean}>(), { disabled: false, proOnly: false });
</script>
2 changes: 1 addition & 1 deletion src/components/StaticPi.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

<script setup lang="ts">
withDefaults(defineProps<{color: string}>(), {
withDefaults(defineProps<{color?: string}>(), {
color: 'pi'
});
Expand Down
12 changes: 6 additions & 6 deletions src/components/ThePage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,12 @@ const loading = computed((): boolean => {
});
withDefaults(defineProps<{
fillHeight: boolean,
heading: string,
headingJustify: VRow['$props']['justify'],
justify: VRow['$props']['justify'],
margin: string,
pageReady: boolean
fillHeight?: boolean,
heading?: string,
headingJustify?: VRow['$props']['justify'],
justify?: VRow['$props']['justify'],
margin?: string,
pageReady?: boolean
}>(), {
fillHeight: false,
heading: '',
Expand Down
2 changes: 1 addition & 1 deletion src/views/Admin/AdminView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
</v-row>

<v-row align='center' justify='center' >
<AdminInvites :inviteCodes='inviteCodes' @update='update'/>
<AdminInvites :inviteCodes='inviteCodes' @update='update'/>
</v-row>

<v-row align='center' justify='center' >
Expand Down
2 changes: 1 addition & 1 deletion src/views/DocumentationView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
:componentKey='componentKey'
:password='password'
/>

<DocConnectWithPassword
:address_token='address_token'
:address_wss_client='address_wss_client'
Expand Down
2 changes: 1 addition & 1 deletion src/views/NetworkStatusView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
<v-icon color='pi' :icon='item.icon' />
</v-col>
<v-col class='ma-0 pa-0'>
<AppSubheading
<SubHeading
:heading='item.heading'
justify='start'
class='unselectable'
Expand Down

0 comments on commit 41495b5

Please sign in to comment.