@topvisor/ui 0.0.35 → 0.0.37

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (267) hide show
  1. package/.chunks/datepicker-6d57a408.es.js +275 -0
  2. package/.chunks/datepicker-6d57a408.es.js.map +1 -0
  3. package/.chunks/datepicker-a0840577.amd.js +234 -0
  4. package/.chunks/datepicker-a0840577.amd.js.map +1 -0
  5. package/.chunks/forms-1aa30229.amd.js +3 -0
  6. package/.chunks/forms-1aa30229.amd.js.map +1 -0
  7. package/.chunks/forms-7be951a7.es.js +962 -0
  8. package/.chunks/forms-7be951a7.es.js.map +1 -0
  9. package/.chunks/popup-604c0a49.amd.js +341 -0
  10. package/.chunks/popup-604c0a49.amd.js.map +1 -0
  11. package/.chunks/popup-b9517276.es.js +700 -0
  12. package/.chunks/popup-b9517276.es.js.map +1 -0
  13. package/README.md +52 -19
  14. package/common/common.amd.js +2 -0
  15. package/common/common.amd.js.map +1 -0
  16. package/common/common.js +2 -0
  17. package/common/common.js.map +1 -0
  18. package/core/core.amd.js +2 -0
  19. package/core/core.amd.js.map +1 -0
  20. package/core/core.js +6 -0
  21. package/core/core.js.map +1 -0
  22. package/core.css +1 -0
  23. package/dark.css +1 -0
  24. package/forms/forms.amd.js +2 -0
  25. package/forms/forms.amd.js.map +1 -0
  26. package/forms/forms.js +16 -0
  27. package/forms/forms.js.map +1 -0
  28. package/forms/helpers.amd.js +2 -0
  29. package/forms/helpers.amd.js.map +1 -0
  30. package/forms/helpers.js +9 -0
  31. package/forms/helpers.js.map +1 -0
  32. package/forms.css +1 -0
  33. package/formsExt/formsExt.amd.js +3 -0
  34. package/formsExt/formsExt.amd.js.map +1 -0
  35. package/formsExt/formsExt.js +220 -0
  36. package/formsExt/formsExt.js.map +1 -0
  37. package/formsExt.css +1 -0
  38. package/{src/resources/icomoon → icomoon}/demo-files/demo.css +161 -161
  39. package/{src/resources/icomoon → icomoon}/demo-files/demo.js +30 -30
  40. package/{src/resources/icomoon → icomoon}/demo.html +2945 -2945
  41. package/{src/resources/icomoon → icomoon}/fonts/Topvisor-2.svg +232 -232
  42. package/{src/resources/icomoon → icomoon}/style.css +647 -647
  43. package/light.css +1 -0
  44. package/package.json +19 -68
  45. package/popup/popup.amd.js +3 -0
  46. package/popup/popup.amd.js.map +1 -0
  47. package/popup/popup.js +144 -0
  48. package/popup/popup.js.map +1 -0
  49. package/popup/worker.amd.js +2 -0
  50. package/popup/worker.amd.js.map +1 -0
  51. package/popup/worker.js +154 -0
  52. package/popup/worker.js.map +1 -0
  53. package/popup.css +1 -0
  54. package/tabs/tabs.amd.js +3 -0
  55. package/tabs/tabs.amd.js.map +1 -0
  56. package/tabs/tabs.js +97 -0
  57. package/tabs/tabs.js.map +1 -0
  58. package/tabs.css +1 -0
  59. package/utils/date.amd.js +2 -0
  60. package/utils/date.amd.js.map +1 -0
  61. package/utils/date.js +6 -0
  62. package/utils/date.js.map +1 -0
  63. package/utils/device.amd.js +2 -0
  64. package/utils/device.amd.js.map +1 -0
  65. package/utils/device.js +6 -0
  66. package/utils/device.js.map +1 -0
  67. package/utils/dom.amd.js +2 -0
  68. package/utils/dom.amd.js.map +1 -0
  69. package/utils/dom.js +64 -0
  70. package/utils/dom.js.map +1 -0
  71. package/.storybook/TopTheme.js +0 -82
  72. package/.storybook/TopThemeManager.js +0 -44
  73. package/.storybook/main.ts +0 -43
  74. package/.storybook/manager.ts +0 -28
  75. package/.storybook/preview-head.html +0 -16
  76. package/.storybook/preview.ts +0 -48
  77. package/.storybook/vue/coreDecorator.ts +0 -19
  78. package/.storybook/vue/vModelDecorator.ts +0 -27
  79. package/.vscode/extensions.json +0 -11
  80. package/.vscode/keybindings.example.json +0 -121
  81. package/.vscode/settings.json +0 -46
  82. package/Dockerfile +0 -3
  83. package/NPM.md +0 -25
  84. package/PUBLISH.md +0 -18
  85. package/STORYBOOK.md +0 -27
  86. package/USE_IN_PROJECT.md +0 -29
  87. package/build/afterBuild.sh +0 -12
  88. package/build/cssModules.ts +0 -39
  89. package/build/plugin/amdFix.ts +0 -46
  90. package/build/rollup.config.ts +0 -18
  91. package/nbproject/project.properties +0 -11
  92. package/nbproject/project.xml +0 -9
  93. package/public/README.md +0 -63
  94. package/src/components/common/common.ts +0 -1
  95. package/src/components/common/icon/icon.ts +0 -4
  96. package/src/components/common/icon/icon.vue +0 -15
  97. package/src/components/component.ts +0 -133
  98. package/src/components/forms/button/button.stories.ts +0 -112
  99. package/src/components/forms/button/button.ts +0 -51
  100. package/src/components/forms/button/button.vue +0 -75
  101. package/src/components/forms/button/stories/README.md +0 -35
  102. package/src/components/forms/button/stories/overview.vue +0 -33
  103. package/src/components/forms/button/style/button.css +0 -124
  104. package/src/components/forms/button/style/style-outline.css +0 -42
  105. package/src/components/forms/button/style/style-soft.css +0 -31
  106. package/src/components/forms/button/style/style-transparent.css +0 -35
  107. package/src/components/forms/checkbox/checkbox.stories.ts +0 -33
  108. package/src/components/forms/checkbox/checkbox.ts +0 -23
  109. package/src/components/forms/checkbox/checkbox.vue +0 -135
  110. package/src/components/forms/checkbox/stories/overview.vue +0 -171
  111. package/src/components/forms/controlLabel/controlLabel.stories.ts +0 -38
  112. package/src/components/forms/controlLabel/controlLabel.ts +0 -4
  113. package/src/components/forms/controlLabel/controlLabel.vue +0 -48
  114. package/src/components/forms/forms.ts +0 -10
  115. package/src/components/forms/helpers.ts +0 -10
  116. package/src/components/forms/hint/hint.stories.ts +0 -46
  117. package/src/components/forms/hint/hint.ts +0 -8
  118. package/src/components/forms/hint/hint.vue +0 -32
  119. package/src/components/forms/input/input.stories.ts +0 -31
  120. package/src/components/forms/input/input.ts +0 -34
  121. package/src/components/forms/input/input.vue +0 -170
  122. package/src/components/forms/input/stories/overview.vue +0 -61
  123. package/src/components/forms/inputDate/datepicker.css +0 -233
  124. package/src/components/forms/inputDate/datepicker.ts +0 -101
  125. package/src/components/forms/inputDate/inputDate.stories.ts +0 -41
  126. package/src/components/forms/inputDate/inputDate.ts +0 -4
  127. package/src/components/forms/inputDate/inputDate.vue +0 -127
  128. package/src/components/forms/inputDate/stories/overview.vue +0 -35
  129. package/src/components/forms/radio/radio.stories.ts +0 -34
  130. package/src/components/forms/radio/radio.ts +0 -15
  131. package/src/components/forms/radio/radio.vue +0 -107
  132. package/src/components/forms/radio/stories/overview.vue +0 -79
  133. package/src/components/forms/select/select.stories.ts +0 -34
  134. package/src/components/forms/select/select.ts +0 -36
  135. package/src/components/forms/select/select.vue +0 -253
  136. package/src/components/forms/select/stories/exampleOptions.ts +0 -71
  137. package/src/components/forms/select/stories/overview.vue +0 -60
  138. package/src/components/forms/switcher/stories/overview.vue +0 -139
  139. package/src/components/forms/switcher/switcher.stories.ts +0 -33
  140. package/src/components/forms/switcher/switcher.ts +0 -22
  141. package/src/components/forms/switcher/switcher.vue +0 -113
  142. package/src/components/forms/textarea/stories/overview.vue +0 -62
  143. package/src/components/forms/textarea/textarea.stories.ts +0 -33
  144. package/src/components/forms/textarea/textarea.ts +0 -38
  145. package/src/components/forms/textarea/textarea.vue +0 -119
  146. package/src/components/formsExt/editArea/editArea.stories.ts +0 -72
  147. package/src/components/formsExt/editArea/editArea.ts +0 -25
  148. package/src/components/formsExt/editArea/editArea.vue +0 -172
  149. package/src/components/formsExt/editArea/stories/README.md +0 -17
  150. package/src/components/formsExt/editArea/stories/overview.vue +0 -66
  151. package/src/components/formsExt/editInput/editInput.stories.ts +0 -36
  152. package/src/components/formsExt/editInput/editInput.ts +0 -20
  153. package/src/components/formsExt/editInput/editInput.vue +0 -57
  154. package/src/components/formsExt/editInput/stories/overview.vue +0 -54
  155. package/src/components/formsExt/formsExt.ts +0 -3
  156. package/src/components/formsExt/radioGroup/radioGroup.stories.ts +0 -51
  157. package/src/components/formsExt/radioGroup/radioGroup.ts +0 -28
  158. package/src/components/formsExt/radioGroup/radioGroup.vue +0 -143
  159. package/src/components/formsExt/radioGroup/stories/overview.vue +0 -78
  160. package/src/components/formsExt/radioGroup/styles/top-scrollBar.css +0 -52
  161. package/src/components/helper.js +0 -10
  162. package/src/components/helpersStories.ts +0 -151
  163. package/src/components/popup/lib/popup.globalEvents.js +0 -205
  164. package/src/components/popup/lib/popup.js +0 -702
  165. package/src/components/popup/lib/worker.globalEvents.js +0 -78
  166. package/src/components/popup/lib/worker.js +0 -232
  167. package/src/components/popup/popup/listItem.vue +0 -42
  168. package/src/components/popup/popup/opener.vue +0 -74
  169. package/src/components/popup/popup/popup.stories.ts +0 -68
  170. package/src/components/popup/popup/popup.ts +0 -93
  171. package/src/components/popup/popup/popup.vue +0 -95
  172. package/src/components/popup/popup/stories/README.md +0 -34
  173. package/src/components/popup/popup/stories/listItems.vue +0 -44
  174. package/src/components/popup/popup/stories/listSubItems.vue +0 -52
  175. package/src/components/popup/popup/stories/overview.vue +0 -208
  176. package/src/components/popup/popup/style/popup.css +0 -243
  177. package/src/components/popup/popup/style/popup.m.css +0 -71
  178. package/src/components/popup/popup/style/popup.pc.css +0 -28
  179. package/src/components/popup/popup.ts +0 -3
  180. package/src/components/popup/worker.ts +0 -1
  181. package/src/components/tabs/tabs/content.vue +0 -24
  182. package/src/components/tabs/tabs/stories/README.md +0 -10
  183. package/src/components/tabs/tabs/tab.vue +0 -52
  184. package/src/components/tabs/tabs/tabs.stories.ts +0 -171
  185. package/src/components/tabs/tabs/tabs.ts +0 -22
  186. package/src/components/tabs/tabs/tabs.vue +0 -64
  187. package/src/components/tabs/tabs.ts +0 -3
  188. package/src/core/base/Colors.stories.ts +0 -15
  189. package/src/core/base/Layout.stories.ts +0 -15
  190. package/src/core/base/Properties.stories.ts +0 -15
  191. package/src/core/base/base.mdx +0 -21
  192. package/src/core/core/core.ts +0 -144
  193. package/src/core/core/events.ts +0 -54
  194. package/src/core/core/options.ts +0 -15
  195. package/src/core/core/state.ts +0 -44
  196. package/src/core/directives/tooltip.ts +0 -55
  197. package/src/core/theme/Colors.stories.ts +0 -15
  198. package/src/core/theme/Properties.stories.ts +0 -15
  199. package/src/core/theme/theme.mdx +0 -15
  200. package/src/core/utils/date.ts +0 -164
  201. package/src/core/utils/device.ts +0 -48
  202. package/src/core/utils/dom.ts +0 -185
  203. package/src/core//320/235/320/260/320/261/320/276/321/200 /320/270/320/272/320/276/320/275/320/276/320/272/gallery.vue" +0 -72
  204. package/src/core//320/235/320/260/320/261/320/276/321/200 /320/270/320/272/320/276/320/275/320/276/320/272//320/235/320/260/320/261/320/276/321/200 /320/270/320/272/320/276/320/275/320/276/320/272.mdx" +0 -31
  205. package/src/core//320/235/320/260/320/261/320/276/321/200 /320/270/320/272/320/276/320/275/320/276/320/272//320/235/320/260/320/261/320/276/321/200 /320/270/320/272/320/276/320/275/320/276/320/272.stories.ts" +0 -14
  206. package/src/docs/CSS/FAQ.mdx +0 -43
  207. package/src/docs/CSS//320/236/320/261/321/211/320/270/320/265 /320/274/320/276/320/264/320/270/321/204/320/270/320/272/320/260/321/202/320/276/321/200/321/213.mdx" +0 -156
  208. package/src/docs/CSS//320/237/320/265/321/200/320/265/320/274/320/265/320/275/320/275/321/213/320/265.mdx +0 -47
  209. package/src/docs/CSS//320/237/321/200/320/265/320/264/320/277/321/200/320/276/321/206/320/265/321/201/321/201/320/276/321/200/321/213.mdx +0 -15
  210. package/src/docs/CSS//320/240/320/265/320/272/320/276/320/274/320/265/320/275/320/264/320/260/321/206/320/270/320/270 /320/221/320/255/320/234.mdx" +0 -49
  211. package/src/docs/CSS//320/241/321/202/320/270/320/273/320/270.md +0 -53
  212. package/src/docs/CSS//320/241/321/202/320/270/320/273/320/270.mdx +0 -4
  213. package/src/docs/CSS//320/247/321/202/320/276 /321/202/320/260/320/272/320/276/320/265 css /320/274/320/276/320/264/321/203/320/273/321/214.mdx" +0 -53
  214. package/src/docs/ROADMAP.md +0 -17
  215. package/src/docs/Roadmap.mdx +0 -4
  216. package/src/docs//320/222/320/262/320/265/320/264/320/265/320/275/320/270/320/265 /320/262 Storybook.mdx" +0 -323
  217. package/src/docs//320/232/320/276/320/274/320/277/320/276/320/275/320/265/320/275/321/202/321/213.mdx +0 -20
  218. package/src/docs//320/237/320/276/320/273/320/265/320/267/320/275/320/260/321/217 /320/270/320/275/321/204/320/276/321/200/320/274/320/260/321/206/320/270/321/217.mdx" +0 -8
  219. package/src/docs//320/241/321/202/320/260/320/275/320/264/320/260/321/200/321/202/321/213 /320/272/320/276/320/264/320/260/IDE.mdx" +0 -42
  220. package/src/docs//320/241/321/202/320/260/320/275/320/264/320/260/321/200/321/202/321/213 /320/272/320/276/320/264/320/260//320/233/320/270/320/275/321/202/320/265/321/200.mdx" +0 -72
  221. package/src/docs//320/241/321/202/320/260/320/275/320/264/320/260/321/200/321/202/321/213 /320/272/320/276/320/264/320/260//320/241/321/202/320/260/320/275/320/264/320/260/321/200/321/202/321/213 /320/272/320/276/320/264/320/260.mdx" +0 -29
  222. package/src/globals.d.ts +0 -1
  223. package/src/resources/styles/core/colors.css +0 -204
  224. package/src/resources/styles/core/components.css +0 -70
  225. package/src/resources/styles/core/core.ts +0 -10
  226. package/src/resources/styles/core/forms/clear.css +0 -19
  227. package/src/resources/styles/core/forms/controls.css +0 -20
  228. package/src/resources/styles/core/forms/focusable.css +0 -26
  229. package/src/resources/styles/core/forms/forms.css +0 -100
  230. package/src/resources/styles/core/icon.css +0 -58
  231. package/src/resources/styles/core/layout.css +0 -40
  232. package/src/resources/styles/core/modifiers/as.css +0 -9
  233. package/src/resources/styles/core/modifiers/ellipsis.css +0 -18
  234. package/src/resources/styles/core/modifiers/modifiers.css +0 -81
  235. package/src/resources/styles/core/modifiers/only.css +0 -19
  236. package/src/resources/styles/core/select.css +0 -16
  237. package/src/resources/styles/jquery-ui.min.css +0 -6
  238. package/src/resources/styles/storybook.css +0 -11
  239. package/src/resources/styles/themes/dark/theme.css +0 -139
  240. package/src/resources/styles/themes/dark.ts +0 -1
  241. package/src/resources/styles/themes/light/theme.css +0 -139
  242. package/src/resources/styles/themes/light.ts +0 -1
  243. package/src/storybook/components/color.vue +0 -45
  244. package/src/storybook/components/colors.vue +0 -34
  245. package/src/storybook/components/icomoon.ts +0 -38
  246. package/src/storybook/components/properties.vue +0 -82
  247. package/src/storybook/resources/accessibility.png +0 -0
  248. package/src/storybook/resources/accessibility.svg +0 -5
  249. package/src/storybook/resources/addon-library.png +0 -0
  250. package/src/storybook/resources/assets.png +0 -0
  251. package/src/storybook/resources/context.png +0 -0
  252. package/src/storybook/resources/discord.svg +0 -15
  253. package/src/storybook/resources/docs.png +0 -0
  254. package/src/storybook/resources/figma-plugin.png +0 -0
  255. package/src/storybook/resources/github.svg +0 -3
  256. package/src/storybook/resources/share.png +0 -0
  257. package/src/storybook/resources/styling.png +0 -0
  258. package/src/storybook/resources/testing.png +0 -0
  259. package/src/storybook/resources/theming.png +0 -0
  260. package/src/storybook/resources/tutorials.svg +0 -12
  261. package/src/storybook/resources/youtube.svg +0 -4
  262. package/src//320/224/320/276/320/261/321/200/320/276 /320/277/320/276/320/266/320/260/320/273/320/276/320/262/320/260/321/202/321/214.mdx" +0 -3
  263. package/tsconfig.json +0 -62
  264. package/vite.config.ts +0 -91
  265. /package/{src/resources/icomoon → icomoon}/fonts/Topvisor-2.ttf +0 -0
  266. /package/{src/resources/icomoon → icomoon}/fonts/Topvisor-2.woff +0 -0
  267. /package/{src/resources/icomoon → icomoon}/selection.json +0 -0
@@ -0,0 +1,220 @@
1
+ import { defineComponent as B, ref as V, watch as w, toRef as g, computed as k, openBlock as i, createElementBlock as n, normalizeClass as m, toDisplayString as v, createCommentVNode as y, createElementVNode as f, createVNode as h, withKeys as b, withModifiers as A, createBlock as C, withCtx as _, createTextVNode as $, mergeProps as K, renderSlot as E, Fragment as I, renderList as M, withDirectives as H, vModelRadio as z } from "vue";
2
+ import { T as N, B as T, _ as G, I as P } from "../.chunks/forms-7be951a7.es.js";
3
+ const R = {
4
+ key: 0,
5
+ class: "top-editArea_title"
6
+ }, U = { class: "top-editArea_footer" }, X = /* @__PURE__ */ B({
7
+ __name: "editArea",
8
+ props: {
9
+ modelValue: {},
10
+ title: {},
11
+ cancelText: { default: "Отмена" },
12
+ submitText: { default: "Отправить" },
13
+ attachToKeyboard: { type: Boolean },
14
+ name: {},
15
+ placeholder: {},
16
+ rows: {},
17
+ minHeight: {},
18
+ expandable: { type: Boolean, default: !0 },
19
+ disabled: { type: Boolean },
20
+ readonly: { type: Boolean },
21
+ isError: { type: Boolean },
22
+ hint: {}
23
+ },
24
+ emits: ["update:modelValue", "cancel"],
25
+ setup(p, { emit: u }) {
26
+ const r = p, o = V(""), l = V(r.modelValue);
27
+ w(g(r, "modelValue"), () => {
28
+ l.value = r.modelValue;
29
+ });
30
+ const t = k(() => l.value !== r.modelValue), d = (e) => {
31
+ u("update:modelValue", e);
32
+ }, a = () => {
33
+ u("cancel"), l.value = r.modelValue;
34
+ };
35
+ return (e, s) => (i(), n("div", {
36
+ class: m({
37
+ "top-editArea": !0,
38
+ "top-editArea-attachedToKeyboard": e.attachToKeyboard
39
+ })
40
+ }, [
41
+ e.title ? (i(), n("div", R, v(e.title), 1)) : y("", !0),
42
+ f("div", {
43
+ class: m({
44
+ "top-editArea_form": !0,
45
+ "top-error": e.isError,
46
+ "top-focus": o.value == "focus"
47
+ })
48
+ }, [
49
+ h(N, {
50
+ modelValue: l.value,
51
+ "onUpdate:modelValue": s[0] || (s[0] = (c) => l.value = c),
52
+ name: e.name,
53
+ placeholder: e.placeholder,
54
+ rows: e.rows,
55
+ minHeight: e.minHeight,
56
+ expandable: e.expandable,
57
+ disabled: e.disabled,
58
+ readonly: e.readonly,
59
+ isError: e.isError,
60
+ hint: e.hint,
61
+ class: "top-editArea_element",
62
+ onFocus: s[1] || (s[1] = (c) => o.value = "focus"),
63
+ onBlur: s[2] || (s[2] = (c) => o.value = ""),
64
+ onKeyup: [
65
+ b(a, ["esc"]),
66
+ s[3] || (s[3] = b(A((c) => d(l.value), ["ctrl"]), ["enter"]))
67
+ ]
68
+ }, null, 8, ["modelValue", "name", "placeholder", "rows", "minHeight", "expandable", "disabled", "readonly", "isError", "hint", "onKeyup"]),
69
+ f("div", U, [
70
+ t.value && (!e.attachToKeyboard || e.modelValue) ? (i(), C(T, {
71
+ key: 0,
72
+ class: "top-editArea_button",
73
+ color: "theme",
74
+ icon: e.attachToKeyboard ? "" : "",
75
+ onClick: a
76
+ }, {
77
+ default: _(() => [
78
+ $(v(e.attachToKeyboard ? "" : e.cancelText), 1)
79
+ ]),
80
+ _: 1
81
+ }, 8, ["icon"])) : y("", !0),
82
+ h(T, {
83
+ class: "top-editArea_button",
84
+ icon: e.attachToKeyboard ? "" : "",
85
+ onClick: s[4] || (s[4] = (c) => d(l.value))
86
+ }, {
87
+ default: _(() => [
88
+ $(v(e.attachToKeyboard ? "" : e.submitText), 1)
89
+ ]),
90
+ _: 1
91
+ }, 8, ["icon"])
92
+ ])
93
+ ], 2)
94
+ ], 2));
95
+ }
96
+ }), D = {
97
+ "top-editArea": "top-editArea",
98
+ "top-editArea_title": "top-editArea_title",
99
+ "top-editArea_form": "top-editArea_form",
100
+ "top-textarea": "top-textarea",
101
+ "top-editArea_element": "top-editArea_element",
102
+ "top-textarea_textarea": "top-textarea_textarea",
103
+ "top-editArea_footer": "top-editArea_footer",
104
+ "top-editArea-attachedToKeyboard": "top-editArea-attachedToKeyboard"
105
+ }, F = {
106
+ $style: D
107
+ }, oe = /* @__PURE__ */ G(X, [["__cssModules", F]]), S = { class: "top-editInput" }, L = /* @__PURE__ */ B({
108
+ __name: "editInput",
109
+ props: {
110
+ modelValue: {},
111
+ input: {},
112
+ button: {}
113
+ },
114
+ emits: ["update:modelValue"],
115
+ setup(p, { emit: u }) {
116
+ const r = p, o = V(r.modelValue);
117
+ w(g(r.modelValue), () => {
118
+ o.value = r.modelValue;
119
+ });
120
+ const l = () => {
121
+ u("update:modelValue", o.value);
122
+ };
123
+ return (t, d) => (i(), n("div", S, [
124
+ h(P, K(t.input, {
125
+ onKeydownCapture: d[0] || (d[0] = b(A((a) => o.value = t.modelValue, ["stop"]), ["esc"])),
126
+ onKeydown: b(A(l, ["stop"]), ["enter"]),
127
+ modelValue: o.value,
128
+ "onUpdate:modelValue": d[1] || (d[1] = (a) => o.value = a)
129
+ }), null, 16, ["onKeydown", "modelValue"]),
130
+ o.value !== t.modelValue ? (i(), C(T, K({
131
+ key: 0,
132
+ icon: "",
133
+ styling: "soft"
134
+ }, t.button, { onClick: l }), {
135
+ default: _(() => [
136
+ E(t.$slots, "default")
137
+ ]),
138
+ _: 3
139
+ }, 16)) : y("", !0)
140
+ ]));
141
+ }
142
+ }), j = {
143
+ "top-editInput": "top-editInput",
144
+ "top-input": "top-input"
145
+ }, q = {
146
+ $style: j
147
+ }, te = /* @__PURE__ */ G(L, [["__cssModules", q]]), J = ["data-top-icon", "onClick"], O = {
148
+ key: 0,
149
+ class: "top-radioGroup_circle"
150
+ }, Q = ["value", "disabled"], W = /* @__PURE__ */ B({
151
+ __name: "radioGroup",
152
+ props: {
153
+ modelValue: {},
154
+ radiosProps: {},
155
+ showIndicator: { type: Boolean },
156
+ size: { default: "s" },
157
+ isError: { type: Boolean }
158
+ },
159
+ emits: ["update:modelValue"],
160
+ setup(p, { emit: u }) {
161
+ const r = p, o = k({
162
+ get() {
163
+ return r.modelValue;
164
+ },
165
+ set(t) {
166
+ u("update:modelValue", t);
167
+ }
168
+ }), l = "radioGroup-" + Math.random();
169
+ return (t, d) => (i(), n("div", {
170
+ class: m({
171
+ "top-radioGroup": !0,
172
+ "top-scrollBarXHidding": !0,
173
+ ["top-size_" + t.size]: !!t.size,
174
+ "top-error": t.isError
175
+ })
176
+ }, [
177
+ (i(!0), n(I, null, M(t.radiosProps, (a) => (i(), n("label", {
178
+ class: m({
179
+ "top-radioGroup_item-selected": a.value === o.value,
180
+ "top-radioGroup_item": !0,
181
+ "top-forms-focusable": !0,
182
+ "top-disabled": a.disabled
183
+ }),
184
+ "data-top-icon": a.icon,
185
+ onClick: (e) => o.value = a.value
186
+ }, [
187
+ $(v(a.title) + " ", 1),
188
+ t.showIndicator ? (i(), n("span", O)) : y("", !0),
189
+ H(f("input", {
190
+ "onUpdate:modelValue": d[0] || (d[0] = (e) => o.value = e),
191
+ name: l,
192
+ type: "radio",
193
+ class: m({
194
+ "top-unvisible": !0
195
+ }),
196
+ value: a.value,
197
+ disabled: a.disabled
198
+ }, null, 8, Q), [
199
+ [z, o.value]
200
+ ])
201
+ ], 10, J))), 256))
202
+ ], 2));
203
+ }
204
+ }), Y = {
205
+ "top-scrollBarXHidding": "top-scrollBarXHidding",
206
+ "top-radioGroup": "top-radioGroup",
207
+ "top-radioGroup_item": "top-radioGroup_item",
208
+ "top-radioGroup_item-selected": "top-radioGroup_item-selected",
209
+ "top-radioGroup_circle": "top-radioGroup_circle",
210
+ "top-disabled": "top-disabled",
211
+ "top-error": "top-error"
212
+ }, Z = {
213
+ $style: Y
214
+ }, ae = /* @__PURE__ */ G(W, [["__cssModules", Z]]);
215
+ export {
216
+ oe as EditArea,
217
+ te as EditInput,
218
+ ae as RadioGroup
219
+ };
220
+ //# sourceMappingURL=formsExt.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"formsExt.js","sources":["../../src/components/formsExt/editArea/editArea.vue","../../src/components/formsExt/editInput/editInput.vue","../../src/components/formsExt/radioGroup/radioGroup.vue"],"sourcesContent":["<script setup lang=\"ts\">\r\nimport { ref, toRef, watch, computed } from 'vue';\r\nimport Button from '@/components/forms/button/button.vue';\r\nimport type { Props, Emits } from './editArea';\r\nimport Textarea from '@/components/forms/textarea/textarea.vue';\r\n\r\n// TODO: добавить переменную top-forms-fixed-height и использовать ее при добавлении отступов у страницы\r\n\r\nconst props = withDefaults(defineProps<Props>(), {\r\n\tcancelText: 'Отмена',\r\n\tsubmitText: 'Отправить',\r\n\texpandable: true,\r\n});\r\n\r\nconst emit = defineEmits<Emits>();\r\n\r\nconst state = ref('');\r\n\r\n/**\r\n * Локальное значение modelValue, будет проброшено вверх только в случае отправки формы\r\n */\r\nconst localValue = ref(props.modelValue);\r\n\r\nwatch(toRef(props, 'modelValue'), () => {\r\n\tlocalValue.value = props.modelValue;\r\n});\r\n\r\nconst isChanged = computed(() => localValue.value !== props.modelValue);\r\n\r\nconst submit = (value: string) => {\r\n\temit('update:modelValue', value);\r\n};\r\n\r\nconst cancel = () => {\r\n\temit('cancel');\r\n\r\n\t// сброс введенного значения\r\n\tlocalValue.value = props.modelValue;\r\n};\r\n</script>\r\n\r\n<template>\r\n\t<div\r\n\t\t:class=\"{\r\n\t\t\t'top-editArea': true,\r\n\t\t\t'top-editArea-attachedToKeyboard': attachToKeyboard,\r\n\t\t}\"\r\n\t>\r\n\t\t<div\r\n\t\t\tv-if=\"title\"\r\n\t\t\tclass=\"top-editArea_title\"\r\n\t\t>\r\n\t\t\t{{ title }}\r\n\t\t</div>\r\n\r\n\t\t<div\r\n\t\t\t:class=\"{\r\n\t\t\t\t'top-editArea_form': true,\r\n\t\t\t\t'top-error': isError,\r\n\t\t\t\t'top-focus': state == 'focus',\r\n\t\t\t}\"\r\n\t\t>\r\n\t\t\t<Textarea\r\n\t\t\t\tv-model=\"localValue\"\r\n\t\t\t\t:name=\"name\"\r\n\t\t\t\t:placeholder=\"placeholder\"\r\n\t\t\t\t:rows=\"rows\"\r\n\t\t\t\t:minHeight=\"minHeight\"\r\n\t\t\t\t:expandable=\"expandable\"\r\n\t\t\t\t:disabled=\"disabled\"\r\n\t\t\t\t:readonly=\"readonly\"\r\n\t\t\t\t:isError=\"isError\"\r\n\t\t\t\t:hint=\"hint\"\r\n\t\t\t\tclass=\"top-editArea_element\"\r\n\t\t\t\t@focus=\"state = 'focus'\"\r\n\t\t\t\t@blur=\"state = ''\"\r\n\t\t\t\t@keyup.esc=\"cancel\"\r\n\t\t\t\t@keyup.ctrl.enter=\"submit(localValue)\"\r\n\t\t\t/>\r\n\r\n\t\t\t<div class=\"top-editArea_footer\">\r\n\t\t\t\t<Button\r\n\t\t\t\t\tv-if=\"isChanged && (!attachToKeyboard || modelValue)\"\r\n\t\t\t\t\tclass=\"top-editArea_button\"\r\n\t\t\t\t\tcolor=\"theme\"\r\n\t\t\t\t\t:icon=\"attachToKeyboard ? '': ''\"\r\n\t\t\t\t\t@click=\"cancel\"\r\n\t\t\t\t>\r\n\t\t\t\t\t{{ attachToKeyboard ? '' : cancelText }}\r\n\t\t\t\t</Button>\r\n\r\n\t\t\t\t<Button\r\n\t\t\t\t\tclass=\"top-editArea_button\"\r\n\t\t\t\t\t:icon=\"attachToKeyboard ? '': ''\"\r\n\t\t\t\t\t@click=\"submit(localValue)\"\r\n\t\t\t\t>\r\n\t\t\t\t\t{{ attachToKeyboard ? '' : submitText }}\r\n\t\t\t\t</Button>\r\n\t\t\t</div>\r\n\t\t</div>\r\n\t</div>\r\n</template>\r\n\r\n<style module>\r\n.top-editArea {\r\n\tdisplay: flex;\r\n\tflex-direction: column;\r\n\tgap: 6px;\r\n}\r\n\r\n.top-editArea_title {\r\n\tfont-size: 12px;\r\n}\r\n\r\n.top-editArea_form {\r\n\tbackground: var(--top-forms-background-color);\r\n\toutline-color: var(--color-theme-75);\r\n\toutline-offset: 0;\r\n\tdisplay: flex;\r\n\tflex-direction: column;\r\n}\r\n\r\n.top-editArea_form:hover {\r\n\tbackground: var(--top-forms-background-color-hover);\r\n}\r\n\r\n/* textarea в EditArea */\r\n.top-textarea {\r\n\twidth: 100%;\r\n}\r\n\r\n.top-editArea_element.top-textarea_textarea {\r\n\tborder: none;\r\n\toutline: none;\r\n\tanimation: none;\r\n}\r\n\r\n/* footer */\r\n.top-editArea_footer {\r\n\tpadding: var(--top-forms-padding);\r\n\tdisplay: flex;\r\n\tjustify-content: flex-end;\r\n\tgap: var(--top-forms-padding);\r\n}\r\n\r\n/* attachedToKeyboard */\r\n.top-editArea-attachedToKeyboard {\r\n\tbackground: var(--top-forms-background-color);\r\n\tmargin-bottom: env(keyboard-inset-height, 0);\r\n\tposition: fixed;\r\n\tbottom: 0;\r\n\tright: 0;\r\n\tleft: 0;\r\n\tz-index: 2;\r\n\tgap: 0;\r\n}\r\n\r\n.top-editArea-attachedToKeyboard .top-editArea_form {\r\n\tborder-radius: 0;\r\n\tborder: none;\r\n\tborder-top: 1px solid var(--top-forms-border-color);\r\n}\r\n\r\n.top-editArea-attachedToKeyboard .top-editArea_title {\r\n\tborder-top: 1px solid var(--color-line-2-opacity);\r\n\tpadding: var(--top-forms-padding);\r\n}\r\n\r\n.top-editArea-attachedToKeyboard .top-editArea_footer > [data-top-icon] {\r\n\tborder-radius: 100%;\r\n}\r\n</style>","<script setup lang=\"ts\">\r\nimport { ref, toRef, watch } from 'vue';\r\nimport type { Props, Emits } from './editInput';\r\nimport Input from '@/components/forms/input/input.vue';\r\nimport Button from '@/components/forms/button/button.vue';\r\n\r\nconst props = defineProps<Props>();\r\n\r\nconst intermediateValue = ref(props.modelValue);\r\n\r\nwatch(toRef(props.modelValue), () => {\r\n\tintermediateValue.value = props.modelValue;\r\n});\r\n\r\nconst emit = defineEmits<Emits>();\r\n\r\nconst submit = () => {\r\n\temit('update:modelValue', intermediateValue.value);\r\n};\r\n</script>\r\n\r\n<template>\r\n\t<div class=\"top-editInput\">\r\n\t\t<Input\r\n\t\t\t:=\"input\"\r\n\t\t\t@keydown.esc.capture.stop=\"intermediateValue = modelValue\"\r\n\t\t\t@keydown.enter.stop=\"submit\"\r\n\t\t\tv-model=\"intermediateValue\"\r\n\t\t/>\r\n\r\n\t\t<Button\r\n\t\t\tv-if=\"intermediateValue !== modelValue\"\r\n\t\t\ticon=\"\"\r\n\t\t\tstyling=\"soft\"\r\n\t\t\t:=\"button\"\r\n\t\t\t@click=\"submit\"\r\n\t\t>\r\n\t\t\t<!-- @slot Слот Button -->\r\n\t\t\t<slot></slot>\r\n\t\t</Button>\r\n\t</div>\r\n</template>\r\n\r\n<style module>\r\n.top-editInput {\r\n\twidth: 220px;\r\n\tflex-grow: 1;\r\n\tdisplay: flex;\r\n\talign-items: flex-end;\r\n\tgap: var(--top-gap-1);\r\n}\r\n\r\n.top-editInput .top-input {\r\n\twidth: unset;\r\n\tflex-grow: 1;\r\n}\r\n</style>","<script setup lang=\"ts\">\r\nimport { computed } from 'vue';\r\nimport type { Props, Emits } from './radioGroup';\r\n\r\nconst props = withDefaults(defineProps<Props>(), {\r\n\tsize: 's',\r\n});\r\n\r\nconst emit = defineEmits<Emits>();\r\n\r\nconst localValue = computed({\r\n\tget() {\r\n\t\treturn props.modelValue;\r\n\t},\r\n\r\n\tset(value) {\r\n\t\temit('update:modelValue', value);\r\n\t},\r\n});\r\n\r\nconst uid = 'radioGroup-' + Math.random();\r\n</script>\r\n\r\n<template>\r\n\t<div\r\n\t\t:class=\"{\r\n\t\t\t['top-radioGroup']: true,\r\n\t\t\t['top-scrollBarXHidding']: true,\r\n\t\t\t['top-size_' + size]: !!size,\r\n\t\t\t['top-error']: isError,\r\n\t\t}\"\r\n\t>\r\n\t\t<label\r\n\t\t\tv-for=\"item of radiosProps\"\r\n\t\t\t:class=\"{\r\n\t\t\t\t['top-radioGroup_item-selected']: item.value === localValue,\r\n\t\t\t\t['top-radioGroup_item']: true,\r\n\t\t\t\t['top-forms-focusable']: true,\r\n\t\t\t\t['top-disabled']: item.disabled,\r\n\t\t\t}\"\r\n\t\t\t:data-top-icon=\"item.icon\"\r\n\t\t\t@click=\"localValue = item.value\"\r\n\t\t>\r\n\t\t\t{{ item.title }}\r\n\r\n\t\t\t<span\r\n\t\t\t\tv-if=\"showIndicator\"\r\n\t\t\t\tclass=\"top-radioGroup_circle\"\r\n\t\t\t></span>\r\n\r\n\t\t\t<!-- Для нативной навигации -->\r\n\t\t\t<input\r\n\t\t\t\tv-model=\"localValue\"\r\n\t\t\t\t:name=\"uid\"\r\n\t\t\t\ttype=\"radio\"\r\n\t\t\t\t:class=\"{\r\n\t\t\t\t\t['top-unvisible']: true,\r\n\t\t\t\t}\"\r\n\t\t\t\t:value=\"item.value\"\r\n\t\t\t\t:disabled=\"item.disabled\"\r\n\t\t\t/>\r\n\t\t</label>\r\n\t</div>\r\n</template>\r\n\r\n<style module>\r\n@import \"./styles/top-scrollBar.css\";\r\n\r\n.top-radioGroup {\r\n\tuser-select: none;\r\n\tbox-sizing: border-box;\r\n\tborder-radius: 8px;\r\n\tbackground-color: var(--color-theme-50);\r\n\theight: var(--top-forms-base-height);\r\n\tpadding: 2px;\r\n\tgap: 2px;\r\n\tdisplay: flex;\r\n\talign-items: flex-start;\r\n}\r\n\r\n.top-radioGroup_item {\r\n\tcursor: pointer;\r\n\tbox-sizing: border-box;\r\n\tborder-radius: 6px;\r\n\theight: calc(var(--top-forms-base-height) - 4px);\r\n\tpadding: 0 16px;\r\n\tfont-weight: 600;\r\n\tdisplay: flex;\r\n\talign-items: center;\r\n\tjustify-content: center;\r\n\tflex-grow: 1;\r\n\tgap: 4px;\r\n}\r\n\r\n.top-radioGroup_item:hover {\r\n\tbackground-color: var(--color-theme-25);\r\n\tbox-shadow: 0px 4px 32px 0px rgba(4, 9, 84, 0.10), 0px 0px 4px 0px rgba(4, 9, 84, 0.08);\r\n}\r\n\r\n/* selected */\r\n.top-radioGroup_item-selected {\r\n\tpointer-events: none;\r\n\tbackground-color: var(--color-bg-3);\r\n\tbox-shadow: 0px 4px 32px 0px rgba(4, 9, 84, 0.10), 0px 0px 4px 0px rgba(4, 9, 84, 0.08);\r\n}\r\n\r\n/* circle */\r\n.top-radioGroup_circle {\r\n\tcontent: \"\";\r\n\tbox-sizing: border-box;\r\n\tborder: 1px solid var(--color-line-3-opacity);\r\n\tborder-radius: 50%;\r\n\tpadding: 3px;\r\n\tmargin-left: auto;\r\n\twidth: calc(var(--top-forms-option-height) - 3px * 2);\r\n\theight: calc(var(--top-forms-option-height) - 3px * 2);\r\n}\r\n\r\n.top-radioGroup_item:hover .top-radioGroup_circle:before {\r\n\tborder-color: var(--color-primary);\r\n}\r\n\r\n/* circle selected */\r\n.top-radioGroup_item-selected .top-radioGroup_circle {\r\n\tborder-color: var(--color-primary);\r\n\tborder-width: 5px;\r\n}\r\n\r\n.top-radioGroup_item-selected:hover .top-radioGroup_circle {\r\n\tborder-color: var(--color-primary-2);\r\n}\r\n\r\n/* top-disabled */\r\n.top-radioGroup_item.top-disabled {\r\n\t--top-icon-color: var(--color-text-3);\r\n\r\n\tcolor: var(--color-text-3);\r\n}\r\n\r\n.top-radioGroup_item.top-disabled .top-radioGroup_circle {\r\n\tborder-color: var(--color-theme-400);\r\n\tbackground-color: var(--color-theme-50);\r\n}\r\n\r\n/* top-error */\r\n.top-radioGroup.top-error .top-radioGroup_item:not(.top-disabled) .top-radioGroup_circle {\r\n\tborder-color: var(--color-negative);\r\n}\r\n</style>"],"names":["state","ref","localValue","props","watch","toRef","isChanged","computed","submit","value","emit","cancel","intermediateValue","uid"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;iBAgBMA,IAAQC,EAAI,EAAE,GAKdC,IAAaD,EAAIE,EAAM,UAAU;AAEvC,IAAAC,EAAMC,EAAMF,GAAO,YAAY,GAAG,MAAM;AACvC,MAAAD,EAAW,QAAQC,EAAM;AAAA,IAAA,CACzB;AAED,UAAMG,IAAYC,EAAS,MAAML,EAAW,UAAUC,EAAM,UAAU,GAEhEK,IAAS,CAACC,MAAkB;AACjC,MAAAC,EAAK,qBAAqBD,CAAK;AAAA,IAAA,GAG1BE,IAAS,MAAM;AACpB,MAAAD,EAAK,QAAQ,GAGbR,EAAW,QAAQC,EAAM;AAAA,IAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBC7BpBS,IAAoBX,EAAIE,EAAM,UAAU;AAE9C,IAAAC,EAAMC,EAAMF,EAAM,UAAU,GAAG,MAAM;AACpC,MAAAS,EAAkB,QAAQT,EAAM;AAAA,IAAA,CAChC;AAID,UAAMK,IAAS,MAAM;AACf,MAAAE,EAAA,qBAAqBE,EAAkB,KAAK;AAAA,IAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBCP5CV,IAAaK,EAAS;AAAA,MAC3B,MAAM;AACL,eAAOJ,EAAM;AAAA,MACd;AAAA,MAEA,IAAIM,GAAO;AACV,QAAAC,EAAK,qBAAqBD,CAAK;AAAA,MAChC;AAAA,IAAA,CACA,GAEKI,IAAM,gBAAgB,KAAK,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
package/formsExt.css ADDED
@@ -0,0 +1 @@
1
+ .top-editArea{display:flex;flex-direction:column;gap:6px}.top-editArea_title{font-size:12px}.top-editArea_form{background:var(--top-forms-background-color);outline-color:var(--color-theme-75);outline-offset:0;display:flex;flex-direction:column}.top-editArea_form:hover{background:var(--top-forms-background-color-hover)}.top-textarea{width:100%}.top-editArea_element.top-textarea_textarea{border:none;outline:none;animation:none}.top-editArea_footer{padding:var(--top-forms-padding);display:flex;justify-content:flex-end;gap:var(--top-forms-padding)}.top-editArea-attachedToKeyboard{background:var(--top-forms-background-color);margin-bottom:env(keyboard-inset-height,0);position:fixed;bottom:0;right:0;left:0;z-index:2;gap:0}.top-editArea-attachedToKeyboard .top-editArea_form{border-radius:0;border:none;border-top:1px solid var(--top-forms-border-color)}.top-editArea-attachedToKeyboard .top-editArea_title{border-top:1px solid var(--color-line-2-opacity);padding:var(--top-forms-padding)}.top-editArea-attachedToKeyboard .top-editArea_footer>[data-top-icon]{border-radius:100%}.top-editInput{width:220px;flex-grow:1;display:flex;align-items:flex-end;gap:var(--top-gap-1)}.top-editInput .top-input{width:unset;flex-grow:1}.top-scrollBarXHidding{scrollbar-width:none;overflow-x:auto;overflow-y:hidden}.top-scrollBarXHidding:hover{scrollbar-width:thin}.top-scrollBarXHidding::-webkit-scrollbar{height:6px;display:none}.top-scrollBarXHidding:hover::-webkit-scrollbar{display:block;scrollbar-width:thin}.top-scrollBarXHidding::-webkit-scrollbar-track{background-color:transparent;box-shadow:inset #0000000f 0 0 0 10px}.top-scrollBarXHidding::-webkit-scrollbar-track:hover{box-shadow:inset #00000014 0 0 0 10px}.top-scrollBarXHidding::-webkit-scrollbar-track:active{box-shadow:inset #0000001a 0 0 0 10px}.top-scrollBarXHidding::-webkit-scrollbar-thumb{background-color:var(--color-line-1-opacity)}.top-scrollBarXHidding::-webkit-scrollbar-thumb:hover{background-color:var(--color-line-2-opacity)}.top-scrollBarXHidding::-webkit-scrollbar-thumb:active{background-color:var(--color-line-3-opacity)}.top-scrollBarXHidding::-webkit-scrollbar-button{width:0;height:0}.top-radioGroup{-webkit-user-select:none;user-select:none;box-sizing:border-box;border-radius:8px;background-color:var(--color-theme-50);height:var(--top-forms-base-height);padding:2px;gap:2px;display:flex;align-items:flex-start}.top-radioGroup_item{cursor:pointer;box-sizing:border-box;border-radius:6px;height:calc(var(--top-forms-base-height) - 4px);padding:0 16px;font-weight:600;display:flex;align-items:center;justify-content:center;flex-grow:1;gap:4px}.top-radioGroup_item:hover{background-color:var(--color-theme-25);box-shadow:0 4px 32px #0409541a,0 0 4px #04095414}.top-radioGroup_item-selected{pointer-events:none;background-color:var(--color-bg-3);box-shadow:0 4px 32px #0409541a,0 0 4px #04095414}.top-radioGroup_circle{content:"";box-sizing:border-box;border:1px solid var(--color-line-3-opacity);border-radius:50%;padding:3px;margin-left:auto;width:calc(var(--top-forms-option-height) - 3px * 2);height:calc(var(--top-forms-option-height) - 3px * 2)}.top-radioGroup_item:hover .top-radioGroup_circle:before{border-color:var(--color-primary)}.top-radioGroup_item-selected .top-radioGroup_circle{border-color:var(--color-primary);border-width:5px}.top-radioGroup_item-selected:hover .top-radioGroup_circle{border-color:var(--color-primary-2)}.top-radioGroup_item.top-disabled{--top-icon-color: var(--color-text-3);color:var(--color-text-3)}.top-radioGroup_item.top-disabled .top-radioGroup_circle{border-color:var(--color-theme-400);background-color:var(--color-theme-50)}.top-radioGroup.top-error .top-radioGroup_item:not(.top-disabled) .top-radioGroup_circle{border-color:var(--color-negative)}
@@ -1,161 +1,161 @@
1
- body {
2
- padding: 0;
3
- margin: 0;
4
- font-family: sans-serif;
5
- font-size: 1em;
6
- line-height: 1.5;
7
- color: #555;
8
- background: #fff;
9
- }
10
- h1 {
11
- font-size: 1.5em;
12
- font-weight: normal;
13
- }
14
- small {
15
- font-size: .66666667em;
16
- }
17
- a {
18
- color: #e74c3c;
19
- text-decoration: none;
20
- }
21
- a:hover, a:focus {
22
- box-shadow: 0 1px #e74c3c;
23
- }
24
- .bshadow0, input {
25
- box-shadow: inset 0 -2px #e7e7e7;
26
- }
27
- input:hover {
28
- box-shadow: inset 0 -2px #ccc;
29
- }
30
- input, fieldset {
31
- font-family: sans-serif;
32
- font-size: 1em;
33
- margin: 0;
34
- padding: 0;
35
- border: 0;
36
- }
37
- input {
38
- color: inherit;
39
- line-height: 1.5;
40
- height: 1.5em;
41
- padding: .25em 0;
42
- }
43
- input:focus {
44
- outline: none;
45
- box-shadow: inset 0 -2px #449fdb;
46
- }
47
- .glyph {
48
- font-size: 16px;
49
- width: 15em;
50
- padding-bottom: 1em;
51
- margin-right: 4em;
52
- margin-bottom: 1em;
53
- float: left;
54
- overflow: hidden;
55
- }
56
- .liga {
57
- width: 80%;
58
- width: calc(100% - 2.5em);
59
- }
60
- .talign-right {
61
- text-align: right;
62
- }
63
- .talign-center {
64
- text-align: center;
65
- }
66
- .bgc1 {
67
- background: #f1f1f1;
68
- }
69
- .fgc1 {
70
- color: #999;
71
- }
72
- .fgc0 {
73
- color: #000;
74
- }
75
- p {
76
- margin-top: 1em;
77
- margin-bottom: 1em;
78
- }
79
- .mvm {
80
- margin-top: .75em;
81
- margin-bottom: .75em;
82
- }
83
- .mtn {
84
- margin-top: 0;
85
- }
86
- .mtl, .mal {
87
- margin-top: 1.5em;
88
- }
89
- .mbl, .mal {
90
- margin-bottom: 1.5em;
91
- }
92
- .mal, .mhl {
93
- margin-left: 1.5em;
94
- margin-right: 1.5em;
95
- }
96
- .mhmm {
97
- margin-left: 1em;
98
- margin-right: 1em;
99
- }
100
- .mls {
101
- margin-left: .25em;
102
- }
103
- .ptl {
104
- padding-top: 1.5em;
105
- }
106
- .pbs, .pvs {
107
- padding-bottom: .25em;
108
- }
109
- .pvs, .pts {
110
- padding-top: .25em;
111
- }
112
- .unit {
113
- float: left;
114
- }
115
- .unitRight {
116
- float: right;
117
- }
118
- .size1of2 {
119
- width: 50%;
120
- }
121
- .size1of1 {
122
- width: 100%;
123
- }
124
- .clearfix:before, .clearfix:after {
125
- content: " ";
126
- display: table;
127
- }
128
- .clearfix:after {
129
- clear: both;
130
- }
131
- .hidden-true {
132
- display: none;
133
- }
134
- .textbox0 {
135
- width: 3em;
136
- background: #f1f1f1;
137
- padding: .25em .5em;
138
- line-height: 1.5;
139
- height: 1.5em;
140
- }
141
- #testDrive {
142
- display: block;
143
- padding-top: 24px;
144
- line-height: 1.5;
145
- }
146
- .fs0 {
147
- font-size: 16px;
148
- }
149
- .fs1 {
150
- font-size: 32px;
151
- }
152
- .fs2 {
153
- font-size: 14px;
154
- }
155
- .fs3 {
156
- font-size: 14px;
157
- }
158
- .fs4 {
159
- font-size: 8px;
160
- }
161
-
1
+ body {
2
+ padding: 0;
3
+ margin: 0;
4
+ font-family: sans-serif;
5
+ font-size: 1em;
6
+ line-height: 1.5;
7
+ color: #555;
8
+ background: #fff;
9
+ }
10
+ h1 {
11
+ font-size: 1.5em;
12
+ font-weight: normal;
13
+ }
14
+ small {
15
+ font-size: .66666667em;
16
+ }
17
+ a {
18
+ color: #e74c3c;
19
+ text-decoration: none;
20
+ }
21
+ a:hover, a:focus {
22
+ box-shadow: 0 1px #e74c3c;
23
+ }
24
+ .bshadow0, input {
25
+ box-shadow: inset 0 -2px #e7e7e7;
26
+ }
27
+ input:hover {
28
+ box-shadow: inset 0 -2px #ccc;
29
+ }
30
+ input, fieldset {
31
+ font-family: sans-serif;
32
+ font-size: 1em;
33
+ margin: 0;
34
+ padding: 0;
35
+ border: 0;
36
+ }
37
+ input {
38
+ color: inherit;
39
+ line-height: 1.5;
40
+ height: 1.5em;
41
+ padding: .25em 0;
42
+ }
43
+ input:focus {
44
+ outline: none;
45
+ box-shadow: inset 0 -2px #449fdb;
46
+ }
47
+ .glyph {
48
+ font-size: 16px;
49
+ width: 15em;
50
+ padding-bottom: 1em;
51
+ margin-right: 4em;
52
+ margin-bottom: 1em;
53
+ float: left;
54
+ overflow: hidden;
55
+ }
56
+ .liga {
57
+ width: 80%;
58
+ width: calc(100% - 2.5em);
59
+ }
60
+ .talign-right {
61
+ text-align: right;
62
+ }
63
+ .talign-center {
64
+ text-align: center;
65
+ }
66
+ .bgc1 {
67
+ background: #f1f1f1;
68
+ }
69
+ .fgc1 {
70
+ color: #999;
71
+ }
72
+ .fgc0 {
73
+ color: #000;
74
+ }
75
+ p {
76
+ margin-top: 1em;
77
+ margin-bottom: 1em;
78
+ }
79
+ .mvm {
80
+ margin-top: .75em;
81
+ margin-bottom: .75em;
82
+ }
83
+ .mtn {
84
+ margin-top: 0;
85
+ }
86
+ .mtl, .mal {
87
+ margin-top: 1.5em;
88
+ }
89
+ .mbl, .mal {
90
+ margin-bottom: 1.5em;
91
+ }
92
+ .mal, .mhl {
93
+ margin-left: 1.5em;
94
+ margin-right: 1.5em;
95
+ }
96
+ .mhmm {
97
+ margin-left: 1em;
98
+ margin-right: 1em;
99
+ }
100
+ .mls {
101
+ margin-left: .25em;
102
+ }
103
+ .ptl {
104
+ padding-top: 1.5em;
105
+ }
106
+ .pbs, .pvs {
107
+ padding-bottom: .25em;
108
+ }
109
+ .pvs, .pts {
110
+ padding-top: .25em;
111
+ }
112
+ .unit {
113
+ float: left;
114
+ }
115
+ .unitRight {
116
+ float: right;
117
+ }
118
+ .size1of2 {
119
+ width: 50%;
120
+ }
121
+ .size1of1 {
122
+ width: 100%;
123
+ }
124
+ .clearfix:before, .clearfix:after {
125
+ content: " ";
126
+ display: table;
127
+ }
128
+ .clearfix:after {
129
+ clear: both;
130
+ }
131
+ .hidden-true {
132
+ display: none;
133
+ }
134
+ .textbox0 {
135
+ width: 3em;
136
+ background: #f1f1f1;
137
+ padding: .25em .5em;
138
+ line-height: 1.5;
139
+ height: 1.5em;
140
+ }
141
+ #testDrive {
142
+ display: block;
143
+ padding-top: 24px;
144
+ line-height: 1.5;
145
+ }
146
+ .fs0 {
147
+ font-size: 16px;
148
+ }
149
+ .fs1 {
150
+ font-size: 32px;
151
+ }
152
+ .fs2 {
153
+ font-size: 14px;
154
+ }
155
+ .fs3 {
156
+ font-size: 14px;
157
+ }
158
+ .fs4 {
159
+ font-size: 8px;
160
+ }
161
+
@@ -1,30 +1,30 @@
1
- if (!('boxShadow' in document.body.style)) {
2
- document.body.setAttribute('class', 'noBoxShadow');
3
- }
4
-
5
- document.body.addEventListener("click", function(e) {
6
- var target = e.target;
7
- if (target.tagName === "INPUT" &&
8
- target.getAttribute('class').indexOf('liga') === -1) {
9
- target.select();
10
- }
11
- });
12
-
13
- (function() {
14
- var fontSize = document.getElementById('fontSize'),
15
- testDrive = document.getElementById('testDrive'),
16
- testText = document.getElementById('testText');
17
- function updateTest() {
18
- testDrive.innerHTML = testText.value || String.fromCharCode(160);
19
- if (window.icomoonLiga) {
20
- window.icomoonLiga(testDrive);
21
- }
22
- }
23
- function updateSize() {
24
- testDrive.style.fontSize = fontSize.value + 'px';
25
- }
26
- fontSize.addEventListener('change', updateSize, false);
27
- testText.addEventListener('input', updateTest, false);
28
- testText.addEventListener('change', updateTest, false);
29
- updateSize();
30
- }());
1
+ if (!('boxShadow' in document.body.style)) {
2
+ document.body.setAttribute('class', 'noBoxShadow');
3
+ }
4
+
5
+ document.body.addEventListener("click", function(e) {
6
+ var target = e.target;
7
+ if (target.tagName === "INPUT" &&
8
+ target.getAttribute('class').indexOf('liga') === -1) {
9
+ target.select();
10
+ }
11
+ });
12
+
13
+ (function() {
14
+ var fontSize = document.getElementById('fontSize'),
15
+ testDrive = document.getElementById('testDrive'),
16
+ testText = document.getElementById('testText');
17
+ function updateTest() {
18
+ testDrive.innerHTML = testText.value || String.fromCharCode(160);
19
+ if (window.icomoonLiga) {
20
+ window.icomoonLiga(testDrive);
21
+ }
22
+ }
23
+ function updateSize() {
24
+ testDrive.style.fontSize = fontSize.value + 'px';
25
+ }
26
+ fontSize.addEventListener('change', updateSize, false);
27
+ testText.addEventListener('input', updateTest, false);
28
+ testText.addEventListener('change', updateTest, false);
29
+ updateSize();
30
+ }());