|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 41 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 41 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 41 KiB |
|
After Width: | Height: | Size: 51 KiB |
|
After Width: | Height: | Size: 51 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 51 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 41 KiB |
|
After Width: | Height: | Size: 51 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
After Width: | Height: | Size: 41 KiB |
|
After Width: | Height: | Size: 41 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 19 KiB |
@ -0,0 +1,7 @@
|
||||
import fs from 'fs';
|
||||
|
||||
function moveFile() {
|
||||
fs.rename('./test.jpg', './public/img/commonShare/test.jpg', (res) => {
|
||||
console.log(res);
|
||||
});
|
||||
}
|
||||
@ -0,0 +1,10 @@
|
||||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
|
||||
function moveFile() {
|
||||
fs.rename('./test.jpg', './public/img/commonShare/test.jpg', (res) => {
|
||||
console.log(res);
|
||||
});
|
||||
}
|
||||
|
||||
moveFile();
|
||||
@ -0,0 +1,81 @@
|
||||
<template>
|
||||
<view
|
||||
:animation="animation_data"
|
||||
class="mask"
|
||||
@click="click_mask"
|
||||
v-if="mask_show"
|
||||
>
|
||||
</view>
|
||||
|
||||
<view
|
||||
class="main-content"
|
||||
:style="{
|
||||
transform: modelValue ? 'translateY(0)' : 'translateY(100%)',
|
||||
...custom_style,
|
||||
}"
|
||||
>
|
||||
<slot></slot>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { defineEmits, ref, watch } from "vue";
|
||||
const props = defineProps({
|
||||
modelValue: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
custom_style: {
|
||||
type: Object,
|
||||
},
|
||||
maskClose: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
});
|
||||
|
||||
const animation_data = ref({});
|
||||
const mask_show = ref(false);
|
||||
|
||||
watch(
|
||||
() => props.modelValue,
|
||||
(newVal) => {
|
||||
mask_show.value = newVal;
|
||||
},
|
||||
{
|
||||
immediate: true,
|
||||
}
|
||||
);
|
||||
|
||||
const emit = defineEmits(["update:modelValue"]);
|
||||
|
||||
const click_mask = () => {
|
||||
if (!props.maskClose) {
|
||||
return;
|
||||
}
|
||||
emit("update:modelValue", false);
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.mask {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100vw;
|
||||
height: 100%;
|
||||
background-color: rgba(0, 0, 0, 0.1);
|
||||
z-index: 9998;
|
||||
}
|
||||
.main-content {
|
||||
z-index: 9999;
|
||||
position: fixed;
|
||||
box-sizing: border-box;
|
||||
transform: translateY(100%);
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
width: 100vw;
|
||||
height: max-content;
|
||||
transition: all 0.4s ease;
|
||||
}
|
||||
</style>
|
||||
@ -1,3 +1,4 @@
|
||||
export * from "./modules/user";
|
||||
export * from "./modules/user/index";
|
||||
export * from "./modules/share";
|
||||
export * from "./modules/home";
|
||||
export * from "./modules/common";
|
||||
|
||||
@ -0,0 +1,19 @@
|
||||
import { defineStore } from "pinia";
|
||||
import { ref } from 'vue'
|
||||
export const useCommonStore = defineStore("common", () => {
|
||||
const show_loading = ref(false);
|
||||
|
||||
const show_loading_close = () => {
|
||||
show_loading.value = false;
|
||||
};
|
||||
|
||||
const show_loading_open = () => {
|
||||
show_loading.value = true;
|
||||
};
|
||||
|
||||
return {
|
||||
show_loading,
|
||||
show_loading_close,
|
||||
show_loading_open,
|
||||
};
|
||||
});
|
||||
@ -0,0 +1 @@
|
||||
export * from './common'
|
||||
@ -0,0 +1 @@
|
||||
export * from "./userShare";
|
||||
@ -1 +1 @@
|
||||
export const baseUrl = "http://101.42.154.98:3000";
|
||||
export const baseUrl = "http://localhost:3000/api/v1";
|
||||
|
||||
@ -1 +0,0 @@
|
||||
export const baseUrl = "http://localhost:3000/api/v1";
|
||||