Compare commits
5 Commits
2b742cbeb7
...
e81f4b9d64
| Author | SHA1 | Date | |
|---|---|---|---|
| e81f4b9d64 | |||
|
fdf3c1319d
|
|||
|
f039ba219d
|
|||
|
52d7dc7a87
|
|||
|
140105f6cb
|
0
.gitmodules
vendored
Normal file
0
.gitmodules
vendored
Normal file
8
.vscode/extensions.json
vendored
8
.vscode/extensions.json
vendored
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"recommendations": [
|
||||
"Webnative.webnative"
|
||||
]
|
||||
}
|
||||
"recommendations": [
|
||||
"Webnative.webnative"
|
||||
]
|
||||
}
|
||||
3
android/.idea/.gitignore
generated
vendored
3
android/.idea/.gitignore
generated
vendored
@@ -1,3 +0,0 @@
|
||||
# Default ignored files
|
||||
/shelf/
|
||||
/workspace.xml
|
||||
6
android/.idea/AndroidProjectSystem.xml
generated
6
android/.idea/AndroidProjectSystem.xml
generated
@@ -1,6 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="AndroidProjectSystem">
|
||||
<option name="providerId" value="com.android.tools.idea.GradleProjectSystem" />
|
||||
</component>
|
||||
</project>
|
||||
6
android/.idea/compiler.xml
generated
6
android/.idea/compiler.xml
generated
@@ -1,6 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="CompilerConfiguration">
|
||||
<bytecodeTargetLevel target="21" />
|
||||
</component>
|
||||
</project>
|
||||
18
android/.idea/deploymentTargetSelector.xml
generated
18
android/.idea/deploymentTargetSelector.xml
generated
@@ -1,18 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="deploymentTargetSelector">
|
||||
<selectionStates>
|
||||
<SelectionState runConfigName="app">
|
||||
<option name="selectionMode" value="DROPDOWN" />
|
||||
<DropdownSelection timestamp="2025-10-14T17:00:16.525383985Z">
|
||||
<Target type="DEFAULT_BOOT">
|
||||
<handle>
|
||||
<DeviceId pluginId="LocalEmulator" identifier="path=/home/chptr/.android/avd/Medium_Phone.avd" />
|
||||
</handle>
|
||||
</Target>
|
||||
</DropdownSelection>
|
||||
<DialogSelection />
|
||||
</SelectionState>
|
||||
</selectionStates>
|
||||
</component>
|
||||
</project>
|
||||
13
android/.idea/deviceManager.xml
generated
13
android/.idea/deviceManager.xml
generated
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="DeviceTable">
|
||||
<option name="columnSorters">
|
||||
<list>
|
||||
<ColumnSorterState>
|
||||
<option name="column" value="Name" />
|
||||
<option name="order" value="ASCENDING" />
|
||||
</ColumnSorterState>
|
||||
</list>
|
||||
</option>
|
||||
</component>
|
||||
</project>
|
||||
10
android/.idea/migrations.xml
generated
10
android/.idea/migrations.xml
generated
@@ -1,10 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectMigrations">
|
||||
<option name="MigrateToGradleLocalJavaHome">
|
||||
<set>
|
||||
<option value="$PROJECT_DIR$" />
|
||||
</set>
|
||||
</option>
|
||||
</component>
|
||||
</project>
|
||||
9
android/.idea/misc.xml
generated
9
android/.idea/misc.xml
generated
@@ -1,9 +0,0 @@
|
||||
<project version="4">
|
||||
<component name="ExternalStorageConfigurationManager" enabled="true" />
|
||||
<component name="ProjectRootManager" version="2" languageLevel="JDK_21" default="true" project-jdk-name="jbr-21" project-jdk-type="JavaSDK">
|
||||
<output url="file://$PROJECT_DIR$/build/classes" />
|
||||
</component>
|
||||
<component name="ProjectType">
|
||||
<option name="id" value="Android" />
|
||||
</component>
|
||||
</project>
|
||||
17
android/.idea/runConfigurations.xml
generated
17
android/.idea/runConfigurations.xml
generated
@@ -1,17 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="RunConfigurationProducerService">
|
||||
<option name="ignoredProducers">
|
||||
<set>
|
||||
<option value="com.intellij.execution.junit.AbstractAllInDirectoryConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.AllInPackageConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.PatternConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.TestInClassConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.UniqueIdConfigurationProducer" />
|
||||
<option value="com.intellij.execution.junit.testDiscovery.JUnitTestDiscoveryConfigurationProducer" />
|
||||
<option value="org.jetbrains.kotlin.idea.junit.KotlinJUnitRunConfigurationProducer" />
|
||||
<option value="org.jetbrains.kotlin.idea.junit.KotlinPatternConfigurationProducer" />
|
||||
</set>
|
||||
</option>
|
||||
</component>
|
||||
</project>
|
||||
@@ -7,7 +7,7 @@ buildscript {
|
||||
mavenCentral()
|
||||
}
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:8.13.0'
|
||||
classpath 'com.android.tools.build:gradle:8.7.2'
|
||||
classpath 'com.google.gms:google-services:4.4.2'
|
||||
|
||||
// NOTE: Do not place your application dependencies here; they belong
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-all.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-all.zip
|
||||
networkTimeout=10000
|
||||
validateDistributionUrl=true
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
|
||||
1189
package-lock.json
generated
1189
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -6,6 +6,7 @@
|
||||
"scripts": {
|
||||
"dev": "ionic serve",
|
||||
"build": "vue-tsc && vite build && npx cap sync",
|
||||
"android": "npm run build && npx cap run android",
|
||||
"preview": "vite preview",
|
||||
"test:e2e": "cypress run",
|
||||
"test:unit": "vitest",
|
||||
@@ -21,13 +22,15 @@
|
||||
"@ionic/vue": "^8.0.0",
|
||||
"@ionic/vue-router": "^8.0.0",
|
||||
"ionicons": "^7.0.0",
|
||||
"pinia": "^3.0.3",
|
||||
"updaterweblibrary": "^1.0.4",
|
||||
"vue": "^3.3.0",
|
||||
"vue-router": "^4.2.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@capacitor/cli": "7.4.3",
|
||||
"@vitejs/plugin-legacy": "^5.0.0",
|
||||
"@vitejs/plugin-vue": "^4.0.0",
|
||||
"@vitejs/plugin-vue": "^4.6.2",
|
||||
"@vue/eslint-config-typescript": "^12.0.0",
|
||||
"@vue/test-utils": "^2.3.0",
|
||||
"cypress": "^13.5.0",
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
<script setup lang="ts">
|
||||
|
||||
import useArchiveStore from "@/stores/archive";
|
||||
import { versionNotes } from "@/utils/types";
|
||||
import {
|
||||
IonButton,
|
||||
IonCard,
|
||||
@@ -13,8 +14,11 @@ IonLabel, IonItem,
|
||||
IonList
|
||||
} from "@ionic/vue";
|
||||
import {chevronForward} from "ionicons/icons";
|
||||
import { ref, watch } from "vue";
|
||||
|
||||
const archive = useArchiveStore();
|
||||
const emit = defineEmits<{(e: "back"): void, (e: "disconnect"): void, (e: "details"):void}>();
|
||||
const versions = ref<versionNotes[]>([]);
|
||||
|
||||
const back = () => {
|
||||
emit("back");
|
||||
@@ -24,10 +28,13 @@ const disconnect = () => {
|
||||
emit("disconnect");
|
||||
};
|
||||
|
||||
const details = () => {
|
||||
const details = (index: number) => {
|
||||
archive.setShownI(index);
|
||||
emit("details");
|
||||
}
|
||||
|
||||
watch(() => archive.getArchive, (newValue) => versions.value = newValue, {immediate: true});
|
||||
|
||||
</script>
|
||||
|
||||
<template>
|
||||
@@ -47,10 +54,10 @@ const details = () => {
|
||||
<ion-card-content>
|
||||
<ion-button @click="back">Back</ion-button>
|
||||
<ion-list lines="full" class="item-scroll">
|
||||
<ion-item :button="true" v-for="i in 10" :key="i" @click="details">
|
||||
<ion-item :button="true" v-for="(version, index) in versions" :key="index" @click="details(index)">
|
||||
<ion-label>
|
||||
<strong>v{{i}}</strong> <br>
|
||||
<ion-note>date</ion-note>
|
||||
<strong>{{version.title}}</strong> <br>
|
||||
<ion-note>{{ version.date }}</ion-note>
|
||||
</ion-label>
|
||||
<div slot="end" class="metadata-end-wrapper">
|
||||
<ion-icon color="medium" :icon="chevronForward"></ion-icon>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
<script setup lang="ts">
|
||||
import useArchiveStore from "@/stores/archive";
|
||||
import {
|
||||
IonButton,
|
||||
IonCard,
|
||||
@@ -7,8 +8,12 @@ import {
|
||||
IonCardSubtitle,
|
||||
IonCardTitle,
|
||||
} from "@ionic/vue";
|
||||
import { versionNotes } from "@/utils/types";
|
||||
import { ref } from "vue";
|
||||
|
||||
const archive = useArchiveStore();
|
||||
const emit = defineEmits<{(e:"back"):void, (e: "disconnect"): void, (e:"choose"): void}>();
|
||||
const record = ref<versionNotes>(archive.getArchive[archive.getShownI]);
|
||||
|
||||
const back = () => {
|
||||
emit("back");
|
||||
@@ -22,6 +27,7 @@ const choose = () => {
|
||||
emit("choose");
|
||||
};
|
||||
|
||||
console.log(archive.getArchive)
|
||||
</script>
|
||||
|
||||
<template>
|
||||
@@ -40,10 +46,11 @@ const choose = () => {
|
||||
<ion-card-content>
|
||||
<ion-card>
|
||||
<ion-card-header>
|
||||
<ion-card-title>Update Name</ion-card-title>
|
||||
<ion-card-title :href="record.link">{{ record.title }}</ion-card-title>
|
||||
</ion-card-header>
|
||||
<ion-card-content>
|
||||
<p>Some blurb about the update</p>
|
||||
<p>{{ record.date as Date }}</p>
|
||||
<p v-html="record.html"></p> <br/>
|
||||
<ion-button @click="choose">Select</ion-button>
|
||||
<ion-button @click="back">Cancel</ion-button>
|
||||
</ion-card-content>
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
<script setup lang="ts">
|
||||
|
||||
import {IonButton, IonCard, IonCardContent, IonCardHeader, IonCardSubtitle, IonCardTitle, IonInput, IonToggle} from "@ionic/vue";
|
||||
import {IonButton, IonCard, IonCardContent, IonCardHeader, IonCardSubtitle, IonCardTitle, IonInput} from "@ionic/vue";
|
||||
import useArchiveStore from "@/stores/archive";
|
||||
import {ref} from "vue";
|
||||
|
||||
const emit = defineEmits<{(e: "disconnect"): void, (e: "back"): void}>();
|
||||
const archive = useArchiveStore();
|
||||
const url = ref<string>(archive.getUrl);
|
||||
|
||||
const disconnect = () => {
|
||||
emit("disconnect")
|
||||
@@ -11,6 +15,12 @@ const disconnect = () => {
|
||||
const back = () => {
|
||||
emit("back")
|
||||
}
|
||||
|
||||
const setSource = () => {
|
||||
console.log(url.value)
|
||||
archive.setUrl(url.value);
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<template>
|
||||
@@ -28,12 +38,8 @@ const back = () => {
|
||||
</ion-card-header>
|
||||
|
||||
<ion-card-content>
|
||||
<ion-input label="Source" placeholder="https://git.example.com/user/repo/releases.rss"></ion-input>
|
||||
<ion-button>Set source</ion-button>
|
||||
<br>
|
||||
<br>
|
||||
<ion-toggle>Allow pre-release versions</ion-toggle>
|
||||
<br>
|
||||
<ion-input label="Source" placeholder="https://git.example.com/user/repo/releases" v-model="url"></ion-input>
|
||||
<ion-button @click="setSource">Set source</ion-button>
|
||||
<br>
|
||||
<ion-button @click="back">Back</ion-button>
|
||||
</ion-card-content>
|
||||
|
||||
12
src/main.ts
12
src/main.ts
@@ -1,8 +1,8 @@
|
||||
import { createApp } from 'vue'
|
||||
import {createApp} from 'vue'
|
||||
import App from './App.vue'
|
||||
import router from './router';
|
||||
|
||||
import { IonicVue } from '@ionic/vue';
|
||||
import {IonicVue} from '@ionic/vue';
|
||||
|
||||
/* Core CSS required for Ionic components to work properly */
|
||||
import '@ionic/vue/css/core.css';
|
||||
@@ -33,11 +33,13 @@ import '@ionic/vue/css/palettes/dark.system.css';
|
||||
|
||||
/* Theme variables */
|
||||
import './theme/variables.css';
|
||||
import {createPinia} from "pinia";
|
||||
|
||||
const app = createApp(App)
|
||||
.use(IonicVue)
|
||||
.use(router);
|
||||
.use(IonicVue)
|
||||
.use(router)
|
||||
.use(createPinia());
|
||||
|
||||
router.isReady().then(() => {
|
||||
app.mount('#app');
|
||||
app.mount('#app');
|
||||
});
|
||||
|
||||
35
src/stores/archive.ts
Normal file
35
src/stores/archive.ts
Normal file
@@ -0,0 +1,35 @@
|
||||
import { defineStore } from "pinia";
|
||||
import Updater from "updaterweblibrary";
|
||||
import type { versionNotes } from "@/utils/types";
|
||||
|
||||
const useArchiveStore = defineStore("archive", {
|
||||
state: () => (
|
||||
{updater: new Updater(), archive: <versionNotes[]>[], shownI: 0}
|
||||
),
|
||||
getters: {
|
||||
getUrl(): string {
|
||||
if (this.updater.archiveURL == "/")
|
||||
return ""
|
||||
else
|
||||
return this.updater.archiveURL;
|
||||
},
|
||||
getArchive(): versionNotes[] {
|
||||
console.log(this.archive)
|
||||
return this.archive;
|
||||
},
|
||||
getShownI(): number {
|
||||
return this.shownI;
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
async setUrl(value: string): Promise<void> {
|
||||
this.updater = new Updater(value, "atom");
|
||||
this.archive = await this.updater.getArchive()
|
||||
},
|
||||
setShownI(value: number): void {
|
||||
this.shownI = value;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
export default useArchiveStore;
|
||||
6
src/utils/types.ts
Normal file
6
src/utils/types.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
export type versionNotes = {
|
||||
title: string;
|
||||
date: Date | string;
|
||||
link: string;
|
||||
html: string;
|
||||
}
|
||||
13
vite.config.js
Normal file
13
vite.config.js
Normal file
@@ -0,0 +1,13 @@
|
||||
import vue from '@vitejs/plugin-vue'
|
||||
import path from "path";
|
||||
|
||||
export default {
|
||||
plugins: [
|
||||
vue()
|
||||
],
|
||||
resolve: {
|
||||
alias: {
|
||||
"@": path.resolve(__dirname, "./src")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
/// <reference types="vitest" />
|
||||
|
||||
import legacy from '@vitejs/plugin-legacy'
|
||||
import vue from '@vitejs/plugin-vue'
|
||||
import path from 'path'
|
||||
import { defineConfig } from 'vite'
|
||||
|
||||
// https://vitejs.dev/config/
|
||||
export default defineConfig({
|
||||
plugins: [
|
||||
vue(),
|
||||
legacy()
|
||||
],
|
||||
resolve: {
|
||||
alias: {
|
||||
'@': path.resolve(__dirname, './src'),
|
||||
},
|
||||
},
|
||||
test: {
|
||||
globals: true,
|
||||
environment: 'jsdom'
|
||||
}
|
||||
})
|
||||
Reference in New Issue
Block a user