From 493120b5456282756d05d9afaf66b11a2f87d8fc Mon Sep 17 00:00:00 2001
From: Alexander Tumin <iamtakingiteasy@eientei.org>
Date: Sat, 18 Mar 2023 20:48:36 +0300
Subject: Generalize IntegerSetting into NumberSetting, add Integer/Float
 wrappers

---
 .../settings_modal/helpers/number_setting.vue      | 27 ++++++++++++++++++++++
 1 file changed, 27 insertions(+)
 create mode 100644 src/components/settings_modal/helpers/number_setting.vue

(limited to 'src/components/settings_modal/helpers/number_setting.vue')

diff --git a/src/components/settings_modal/helpers/number_setting.vue b/src/components/settings_modal/helpers/number_setting.vue
new file mode 100644
index 00000000..3eab5178
--- /dev/null
+++ b/src/components/settings_modal/helpers/number_setting.vue
@@ -0,0 +1,27 @@
+<template>
+  <span
+    v-if="matchesExpertLevel"
+    class="NumberSetting"
+  >
+    <label :for="path">
+      <slot />
+    </label>
+    <input
+      :id="path"
+      class="number-input"
+      type="number"
+      :step="step || 1"
+      :disabled="disabled"
+      :min="min || 0"
+      :value="state"
+      @change="update"
+    >
+    {{ ' ' }}
+    <ModifiedIndicator
+      :changed="isChanged"
+      :onclick="reset"
+    />
+  </span>
+</template>
+
+<script src="./number_setting.js"></script>
-- 
cgit v1.2.3-70-g09d2

