小程序初始提交
This commit is contained in:
16
cool-unix/uni_modules/cool-ui/components/cl-footer/offset.ts
Normal file
16
cool-unix/uni_modules/cool-ui/components/cl-footer/offset.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
import { router } from "@/cool";
|
||||
import { reactive } from "vue";
|
||||
|
||||
export class ClFooterOffset {
|
||||
private data = reactive({});
|
||||
|
||||
set(value: number): void {
|
||||
this.data[router.path()] = value;
|
||||
}
|
||||
|
||||
get(): number {
|
||||
return (this.data[router.path()] as number | null) ?? 0;
|
||||
}
|
||||
}
|
||||
|
||||
export const clFooterOffset = new ClFooterOffset();
|
||||
Reference in New Issue
Block a user