mirror of
https://github.com/Dvorinka/swingmusic-extended.git
synced 2026-06-05 04:53:01 +00:00
add context menu options placeholder function
This commit is contained in:
+13
-1
@@ -3,10 +3,22 @@ import normalize from "../composables/normalizeContextMenu";
|
||||
import { Option } from "../interfaces";
|
||||
import { ContextSrc } from "../composables/enums";
|
||||
|
||||
function getPlaceholders(length: number) {
|
||||
let list: Option[] = [];
|
||||
|
||||
for (let index = 0; index < length; index++) {
|
||||
list.push("" as Option);
|
||||
}
|
||||
|
||||
return list;
|
||||
}
|
||||
|
||||
getPlaceholders(5);
|
||||
|
||||
export default defineStore("context-menu", {
|
||||
state: () => ({
|
||||
visible: false,
|
||||
options: <Option[]>[],
|
||||
options: getPlaceholders(5),
|
||||
x: 500,
|
||||
y: 500,
|
||||
normalizedX: false,
|
||||
|
||||
Reference in New Issue
Block a user