From 8f0c9fa6be7d90c57f5f521eb15c85ff8a048fa3 Mon Sep 17 00:00:00 2001 From: Nikita-Polyakov Date: Tue, 29 Jun 2021 11:35:48 +0300 Subject: [PATCH 01/11] pass icon path, install other plugins inside index --- src/components/index.ts | 8 ++++++-- src/index.ts | 12 ++++++++++++ src/plugins/elementUI.ts | 24 ++++++++++++++---------- src/plugins/index.ts | 4 ++-- src/plugins/jsonUI.ts | 5 +---- src/stories/SJsonInput.stories.ts | 4 ++++ src/styles/collapse.scss | 2 +- src/styles/common.scss | 4 ++-- src/styles/datepicker.scss | 2 +- src/styles/fonts.scss | 6 +++--- src/styles/icons.scss | 3 +-- src/styles/index.scss | 1 + src/styles/index.ts | 1 - src/styles/input.scss | 2 +- src/styles/json-input.scss | 8 ++++---- src/styles/neumorphism/button.scss | 13 +++++++++++++ src/styles/root.scss | 20 ++++++++++++-------- src/styles/scroll-sections.scss | 2 +- src/styles/select.scss | 4 ++-- src/styles/table.scss | 2 +- src/styles/variables.scss | 3 +++ 21 files changed, 85 insertions(+), 45 deletions(-) delete mode 100644 src/styles/index.ts diff --git a/src/components/index.ts b/src/components/index.ts index b2f4448c..7663ae69 100644 --- a/src/components/index.ts +++ b/src/components/index.ts @@ -1,7 +1,9 @@ -import '../plugins' -import '../styles' +import Vue from 'vue' + import '../styles/index.scss' +import { ElementUIPlugin } from '../plugins' + import { SApp } from './Layout/App' import { SAside } from './Layout/Aside' import { SBreadcrumb, SBreadcrumbItem } from './Breadcrumb' @@ -34,6 +36,8 @@ import { STab, STabs } from './Tab' import { STable, SHierarchicalTable, STableColumn } from './Table' import { STooltip } from './Tooltip' +Vue.use(ElementUIPlugin) + export { SApp, SAside, diff --git a/src/index.ts b/src/index.ts index 9f43d725..cb9dfe87 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,5 +1,9 @@ import Vue from 'vue' +import { + VJsoneditor +} from './plugins' + import { SApp, SAside, @@ -50,6 +54,7 @@ import { STableColumn, STooltip } from './components' + import { Float, Integer } from './directives' import { Components } from './types/components' import { Directives } from './types/directives' @@ -111,6 +116,8 @@ const components = [ { component: STooltip, name: Components.STooltip } ] +const plugins = [VJsoneditor] + const directives = [ { directive: Float, name: Directives.Float }, { directive: Integer, name: Directives.Integer } @@ -118,6 +125,10 @@ const directives = [ const SoramitsuElements = { install (vue: typeof Vue, options?: any): void { + const pluginsToInstall = options && options.plugins ? options.plugins : plugins + + pluginsToInstall.forEach(plugin => vue.use(plugin)) + // TODO: maybe we'll need error message about storage here if (options && options.store) { Object.values(Modules).forEach(molude => { @@ -138,6 +149,7 @@ export { Themes, setDesignSystem, DesignSystemTypes, + VJsoneditor, Loading, Message, MessageBox, diff --git a/src/plugins/elementUI.ts b/src/plugins/elementUI.ts index 0b71c0e0..3f677b6f 100644 --- a/src/plugins/elementUI.ts +++ b/src/plugins/elementUI.ts @@ -1,21 +1,25 @@ -import Vue from 'vue' import Element, { Loading, Message, - MessageBox as MsgBox, + MessageBox, Notification } from 'element-ui' import i18n from '../lang' -Vue.use(Loading.directive) -Vue.use(Element, { i18n: (key, value) => i18n.t(key, value) }) -const MessageBox = MsgBox -Vue.prototype.$loading = Loading.service -Vue.prototype.$prompt = MessageBox.prompt -Vue.prototype.$alert = MessageBox.alert -Vue.prototype.$message = Message -Vue.prototype.$notify = Notification +const ElementUIPlugin = { + install: (Vue) => { + Vue.use(Loading.directive) + Vue.use(Element, { i18n: (key, value) => i18n.t(key, value) }) + Vue.prototype.$loading = Loading.service + Vue.prototype.$prompt = MessageBox.prompt + Vue.prototype.$alert = MessageBox.alert + Vue.prototype.$message = Message + Vue.prototype.$notify = Notification + } +} + +export default ElementUIPlugin export { Loading, diff --git a/src/plugins/index.ts b/src/plugins/index.ts index 9caf87fd..2bce8741 100644 --- a/src/plugins/index.ts +++ b/src/plugins/index.ts @@ -1,2 +1,2 @@ -import './elementUI' -import './jsonUI' +export { default as ElementUIPlugin } from './elementUI' +export { VJsoneditor } from './jsonUI' diff --git a/src/plugins/jsonUI.ts b/src/plugins/jsonUI.ts index 34ddfedb..b543b31a 100644 --- a/src/plugins/jsonUI.ts +++ b/src/plugins/jsonUI.ts @@ -1,4 +1 @@ -import Vue from 'vue' -import VJsoneditor from 'v-jsoneditor' - -Vue.use(VJsoneditor) +export { default as VJsoneditor } from 'v-jsoneditor' diff --git a/src/stories/SJsonInput.stories.ts b/src/stories/SJsonInput.stories.ts index 68adc1e6..4f6d90fc 100644 --- a/src/stories/SJsonInput.stories.ts +++ b/src/stories/SJsonInput.stories.ts @@ -1,6 +1,10 @@ +import Vue from 'vue' import { text, withKnobs, boolean } from '@storybook/addon-knobs' import { SJsonInput, SRow } from '../components' +import { VJsoneditor } from '../plugins' + +Vue.use(VJsoneditor) export default { component: SJsonInput, diff --git a/src/styles/collapse.scss b/src/styles/collapse.scss index c283ac2f..189240bd 100644 --- a/src/styles/collapse.scss +++ b/src/styles/collapse.scss @@ -28,7 +28,7 @@ border-bottom-color: transparent; } .el-icon-arrow-right { - font-family: $s-font-family-icons; + font-family: var(--s-font-family-icons); @extend .s-icon-chevron-down-rounded-16; font-size: var(--s-icon-font-size-mini); padding: 8px; diff --git a/src/styles/common.scss b/src/styles/common.scss index 5f400cec..ed5c12c9 100644 --- a/src/styles/common.scss +++ b/src/styles/common.scss @@ -1,6 +1,6 @@ [class^="el-"]:not(i):not([class*='el-icon']), [class*="el-"]:not(i):not([class*='el-icon']) { - font-family: $s-font-family-default; + font-family: var(--s-font-family-default); } html { @@ -32,7 +32,7 @@ h1, h2, h3, h4, h5, h6, .d1, .d2, .ch1, .ch2, .ch3, .p1, .p2, .p3, .p4 { - font-family: $s-font-family-default; + font-family: var(--s-font-family-default); font-feature-settings: var(--s-font-feature-settings-heading); } diff --git a/src/styles/datepicker.scss b/src/styles/datepicker.scss index e289ae77..0fc83efb 100644 --- a/src/styles/datepicker.scss +++ b/src/styles/datepicker.scss @@ -18,7 +18,7 @@ $date-picker-padding: 8px; .s-date-picker { - font-family: $s-font-family-default; + font-family: var(--s-font-family-default); width: 100%; position: relative; &.s-big .el-input__inner { diff --git a/src/styles/fonts.scss b/src/styles/fonts.scss index 71134b84..29cfd59c 100644 --- a/src/styles/fonts.scss +++ b/src/styles/fonts.scss @@ -1,18 +1,18 @@ @font-face { font-family: "soramitsu-icons"; - src: url("~@/assets/fonts/soramitsu-icons-1.0.0.ttf") format("truetype"); + src: url(#{$s-font-family-icons-path}) format("truetype"); font-weight: normal; font-style: normal; font-display: block; } @font-face { font-family: "Sora"; - src: url("~@/assets/fonts/Sora-VariableFont_wght.ttf") format("truetype-variations"); + src: url(#{$s-font-family-default-path}) format("truetype-variations"); font-weight: 1 999; } @font-face { font-family: "JetBrainsMono"; - src: url("~@/assets/fonts/JetBrainsMono-Regular.woff"); + src: url(#{$s-font-family-mono-path}); font-weight: normal; font-style: normal; } diff --git a/src/styles/icons.scss b/src/styles/icons.scss index 049b7745..39ae83d2 100644 --- a/src/styles/icons.scss +++ b/src/styles/icons.scss @@ -1,5 +1,5 @@ [class^="s-icon-"], [class*=" s-icon-"] { - font-family: 'soramitsu-icons' !important; + font-family: var(--s-font-family-icons); font-style: normal; font-weight: normal; font-variant: normal; @@ -9,7 +9,6 @@ -moz-osx-font-smoothing: grayscale; color: var(--s-color-base-content-primary); } -$icons-font: 'soramitsu-icons' !important; /*_____________________________________________Icons variables_____________________________________________*/ $s-icon-arrow-bottom-16: "\eb11"; $s-icon-arrow-bottom-left-16: "\eb12"; diff --git a/src/styles/index.scss b/src/styles/index.scss index a98775f4..dad8fe9e 100644 --- a/src/styles/index.scss +++ b/src/styles/index.scss @@ -1,6 +1,7 @@ // @import "./neumorphism/theme-variables"; // uncomment to preview components with neu variables @import "./variables"; @import "./element-variables"; +@import "./fonts.scss"; @import "./common"; @import "./button"; @import "./breadcrumbs"; diff --git a/src/styles/index.ts b/src/styles/index.ts deleted file mode 100644 index 4591aad9..00000000 --- a/src/styles/index.ts +++ /dev/null @@ -1 +0,0 @@ -import './fonts.scss' diff --git a/src/styles/input.scss b/src/styles/input.scss index 47b03225..c60f490e 100644 --- a/src/styles/input.scss +++ b/src/styles/input.scss @@ -23,7 +23,7 @@ $input-padding-left: $s-basic-spacing * 2 - $input-border-width; border-color: var(--s-color-base-background); border-style: solid; border-width: $input-border-width; - font-family: $s-font-family-default; + font-family: var(--s-font-family-default); height: $s-size-big; padding: $input-padding-top $input-padding-left; position: relative; diff --git a/src/styles/json-input.scss b/src/styles/json-input.scss index 9e0689cd..9a0a3c9a 100644 --- a/src/styles/json-input.scss +++ b/src/styles/json-input.scss @@ -45,7 +45,7 @@ $footer-height: 26px; .jsoneditor { border: none !important; - font-family: $s-font-family-mono; + font-family: var(--s-font-family-mono); .jsoneditor-outer { height: calc(100% - #{$footer-height}); margin-bottom: -1px !important; @@ -53,7 +53,7 @@ $footer-height: 26px; } .ace-jsoneditor { *, textarea.jsoneditor-text * { - font-family: $s-font-family-mono; + font-family: var(--s-font-family-mono); } .ace_fold { border: none; @@ -114,10 +114,10 @@ $footer-height: 26px; } .ace_editor .ace_content, .ace_gutter .ace_gutter-cell { - font-family: $s-font-family-mono; + font-family: var(--s-font-family-mono); } .ace_tooltip { - font-family: $s-font-family-default; + font-family: var(--s-font-family-default); background: var(--s-color-base-content-primary); border-color: var(--s-color-base-content-primary); color: var(--s-color-base-on-accent); diff --git a/src/styles/neumorphism/button.scss b/src/styles/neumorphism/button.scss index a993c5d3..b0f9bdb4 100644 --- a/src/styles/neumorphism/button.scss +++ b/src/styles/neumorphism/button.scss @@ -151,17 +151,30 @@ $neu-button-padding-mini: 3px 6px !default; box-shadow: $neu-button-primary-box-shadow; color: $neu-button-primary-text-color; + i { + color: $neu-button-primary-text-color; + } + &:hover, &:focus, &.focusing { background: $neu-button-primary-background-color-hover; border-color: $neu-button-primary-border-color-hover; color: $neu-button-primary-text-color-hover; box-shadow: $neu-button-primary-box-shadow-hover; + + i { + color: $neu-button-primary-text-color-hover; + } + } &:active, &.s-pressed { background: $neu-button-primary-background-color-pressed; border-color: $neu-button-primary-border-color-pressed; color: $neu-button-primary-text-color-pressed; box-shadow: $neu-button-primary-box-shadow-pressed; + + i { + color: $neu-button-primary-text-color-pressed; + } } @include disabled; diff --git a/src/styles/root.scss b/src/styles/root.scss index c6cd697e..b3956a8d 100644 --- a/src/styles/root.scss +++ b/src/styles/root.scss @@ -29,6 +29,10 @@ --s-color-status-success-background: #{$s-color-status-success-background}; --s-color-status-warning-background: #{$s-color-status-warning-background}; --s-color-status-error-background: #{$s-color-status-error-background}; + // Fonts + --s-font-family-default: #{$s-font-family-default}; + --s-font-family-mono: #{$s-font-family-mono}; + --s-font-family-icons: #{$s-font-family-icons}; // Font Sizes --s-font-size-extra-mini: #{$s-font-size-extra-mini}; --s-font-size-mini: #{$s-font-size-mini}; @@ -68,14 +72,14 @@ --s-letter-spacing-large: #{$s-letter-spacing-large}; --s-letter-spacing-extra-large: #{$s-letter-spacing-extra-large}; // Font Feature Settings - --s-font-feature-settings-common: "tnum" on, "lnum" on, "case" on, "salt" on, "ss01" on; // $s-font-feature-settings-common - --s-font-feature-settings-heading: "tnum" on, "lnum" on, "salt" on, "case" on; // $s-font-feature-settings-heading - --s-font-feature-settings-caps-heading: "tnum" on, "lnum" on, "case" on; // $s-font-feature-settings-caps-heading - --s-font-feature-settings-caps: "case" on; // $s-font-feature-settings-caps - --s-font-feature-settings-singleline: "salt" on, "case" on; // $s-font-feature-settings-singleline - --s-font-feature-settings-card-title: "tnum" on, "lnum" on, "ss01" on; // $s-font-feature-settings-card-title - --s-font-feature-settings-input: "tnum" on, "lnum" on; // $s-font-feature-settings-input - --s-font-feature-settings-button: "tnum" on, "lnum" on, "salt" on; // $s-font-feature-settings-button + --s-font-feature-settings-common: #{$s-font-feature-settings-common}; + --s-font-feature-settings-heading: #{$s-font-feature-settings-heading}; + --s-font-feature-settings-caps-heading: #{$s-font-feature-settings-caps-heading}; + --s-font-feature-settings-caps: #{$s-font-feature-settings-caps}; + --s-font-feature-settings-singleline: #{$s-font-feature-settings-singleline}; + --s-font-feature-settings-card-title: #{$s-font-feature-settings-card-title}; + --s-font-feature-settings-input: #{$s-font-feature-settings-input}; + --s-font-feature-settings-button: #{$s-font-feature-settings-button}; // Size --s-size-mini: #{$s-size-mini}; --s-size-small: #{$s-size-small}; diff --git a/src/styles/scroll-sections.scss b/src/styles/scroll-sections.scss index 9076a17b..8e455dcc 100644 --- a/src/styles/scroll-sections.scss +++ b/src/styles/scroll-sections.scss @@ -1,5 +1,5 @@ .s-scroll-sections { - font-family: $s-font-family-default; + font-family: var(--s-font-family-default); font-size: var(--s-font-size-small); } .s-scroll-menu { diff --git a/src/styles/select.scss b/src/styles/select.scss index 828439a8..665e1ce0 100644 --- a/src/styles/select.scss +++ b/src/styles/select.scss @@ -20,7 +20,7 @@ $select-prefix-width: $s-size-mini; $select-prefix-height: $s-size-mini; .s-select { - font-family: $s-font-family-default; + font-family: var(--s-font-family-default); width: 100%; position: relative; @include select-border-radius; @@ -45,7 +45,7 @@ $select-prefix-height: $s-size-mini; display: flex; align-items: center; width: var(--s-icon-font-size-big); - font-family: $icons-font; + font-family: var(--s-font-family-icons); font-size: var(--s-icon-font-size-big); &:before { content: $s-icon-arrows-chevron-top-rounded-24; diff --git a/src/styles/table.scss b/src/styles/table.scss index 19f89ae0..5e5f7128 100644 --- a/src/styles/table.scss +++ b/src/styles/table.scss @@ -127,7 +127,7 @@ left: 0; top: 0; > .el-icon.el-icon-arrow-right { - font-family: $s-font-family-icons; + font-family: var(--s-font-family-icons); @extend .s-icon-chevron-down-rounded-16; } &--expanded { diff --git a/src/styles/variables.scss b/src/styles/variables.scss index 8a37773d..c036f649 100644 --- a/src/styles/variables.scss +++ b/src/styles/variables.scss @@ -65,8 +65,11 @@ $s-border-radius-big: $s-border-radius-base * 4 !default; // Fonts $s-font-family-default: 'Sora', sans-serif !important; +$s-font-family-default-path: '~@/assets/fonts/Sora-VariableFont_wght.ttf' !default; $s-font-family-mono: 'JetBrainsMono', monospace !important; +$s-font-family-mono-path: '~@/assets/fonts/JetBrainsMono-Regular.woff' !default; $s-font-family-icons: 'soramitsu-icons' !important; +$s-font-family-icons-path: '~@/assets/fonts/soramitsu-icons-1.0.0.ttf' !default; // Font sizes $s-font-size-extra-mini: 11px !default; $s-font-size-mini: 12px !default; From 2cf8ec40de6afd0e4f9266c5ef908e21be107f90 Mon Sep 17 00:00:00 2001 From: Nikita-Polyakov Date: Tue, 29 Jun 2021 11:39:07 +0300 Subject: [PATCH 02/11] up version to 0.9.12 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 6ea348a8..805173c3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@soramitsu/soramitsu-js-ui", - "version": "0.9.11", + "version": "0.9.12", "private": false, "publishConfig": { "registry": "https://nexus.iroha.tech/repository/npm-soramitsu/" From 93179a532720e43d5bb620b04a9f256759d0bddc Mon Sep 17 00:00:00 2001 From: Nikita-Polyakov Date: Tue, 29 Jun 2021 16:00:43 +0300 Subject: [PATCH 03/11] update Readme --- README.md | 10 ++++++++++ src/styles/index.scss | 2 +- tsconfig.json | 1 + 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 3cf61576..152b0bcf 100644 --- a/README.md +++ b/README.md @@ -5,6 +5,16 @@ yarn install ``` +## Font variables setup +Add font variables to your project + +``` +$s-font-family-default-path: '~@soramitsu/soramitsu-js-ui/lib/assets/fonts/Sora-VariableFont_wght.ttf' !default; +$s-font-family-mono-path: '~@soramitsu/soramitsu-js-ui/lib/assets/fonts/JetBrainsMono-Regular.woff' !default; +$s-font-family-icons-path: '~@soramitsu/soramitsu-js-ui/lib/assets/fonts/soramitsu-icons-1.0.0.ttf' !default; +``` + + ### Compiles and hot-reloads storybook with components for development ``` yarn storybook:serve diff --git a/src/styles/index.scss b/src/styles/index.scss index dad8fe9e..bfa5c946 100644 --- a/src/styles/index.scss +++ b/src/styles/index.scss @@ -1,7 +1,7 @@ // @import "./neumorphism/theme-variables"; // uncomment to preview components with neu variables @import "./variables"; @import "./element-variables"; -@import "./fonts.scss"; +@import "./fonts"; @import "./common"; @import "./button"; @import "./breadcrumbs"; diff --git a/tsconfig.json b/tsconfig.json index 8d0b967e..50cc1b58 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -17,6 +17,7 @@ "baseUrl": ".", "types": [ "webpack-env", + "element-ui", "jest" ], "paths": { From b4b8429e9d7ca9bdf8b9bcf3828a82bd40dc6a6d Mon Sep 17 00:00:00 2001 From: Nikita-Polyakov Date: Tue, 29 Jun 2021 16:19:10 +0300 Subject: [PATCH 04/11] refactoring --- src/index.ts | 8 +++----- src/plugins/elementUI.ts | 18 ++++++++++-------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/src/index.ts b/src/index.ts index cb9dfe87..02f9fd5e 100644 --- a/src/index.ts +++ b/src/index.ts @@ -116,8 +116,6 @@ const components = [ { component: STooltip, name: Components.STooltip } ] -const plugins = [VJsoneditor] - const directives = [ { directive: Float, name: Directives.Float }, { directive: Integer, name: Directives.Integer } @@ -125,9 +123,9 @@ const directives = [ const SoramitsuElements = { install (vue: typeof Vue, options?: any): void { - const pluginsToInstall = options && options.plugins ? options.plugins : plugins - - pluginsToInstall.forEach(plugin => vue.use(plugin)) + if (options && options.plugins) { + options.plugins.forEach(plugin => vue.use(plugin)) + } // TODO: maybe we'll need error message about storage here if (options && options.store) { diff --git a/src/plugins/elementUI.ts b/src/plugins/elementUI.ts index 3f677b6f..3f640411 100644 --- a/src/plugins/elementUI.ts +++ b/src/plugins/elementUI.ts @@ -1,3 +1,5 @@ +import Vue from 'vue' + import Element, { Loading, Message, @@ -8,14 +10,14 @@ import Element, { import i18n from '../lang' const ElementUIPlugin = { - install: (Vue) => { - Vue.use(Loading.directive) - Vue.use(Element, { i18n: (key, value) => i18n.t(key, value) }) - Vue.prototype.$loading = Loading.service - Vue.prototype.$prompt = MessageBox.prompt - Vue.prototype.$alert = MessageBox.alert - Vue.prototype.$message = Message - Vue.prototype.$notify = Notification + install: (vue: typeof Vue) => { + vue.use(Loading.directive) + vue.use(Element, { i18n: (key, value) => i18n.t(key, value) }) + vue.prototype.$loading = Loading.service + vue.prototype.$prompt = MessageBox.prompt + vue.prototype.$alert = MessageBox.alert + vue.prototype.$message = Message + vue.prototype.$notify = Notification } } From ac6f44e64bb992c020818d185959552b42516ff9 Mon Sep 17 00:00:00 2001 From: Nikita-Polyakov Date: Tue, 29 Jun 2021 16:24:11 +0300 Subject: [PATCH 05/11] update Readme --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index 152b0bcf..beeac5a1 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,14 @@ $s-font-family-mono-path: '~@soramitsu/soramitsu-js-ui/lib/assets/fonts/JetBrain $s-font-family-icons-path: '~@soramitsu/soramitsu-js-ui/lib/assets/fonts/soramitsu-icons-1.0.0.ttf' !default; ``` +## Additional plugins setup +``` +import Vue from 'vue' +import SoramitsuElements, { VJsoneditor } from '@soramitsu/soramitsu-js-ui' + +Vue.use(SoramitsuElements, { plugins: [VJsoneditor] }) +``` + ### Compiles and hot-reloads storybook with components for development ``` From c33610bfeb3c8b4d2dfc4a36c169c66bdc8ab76b Mon Sep 17 00:00:00 2001 From: Nikita-Polyakov Date: Wed, 30 Jun 2021 08:48:50 +0300 Subject: [PATCH 06/11] move vue-i18n to dependencies --- package.json | 2 +- tsconfig.json | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 805173c3..166b8858 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,7 @@ "v-jsoneditor": "^1.4.1", "vue": "^2.6.11", "vue-class-component": "^7.2.3", + "vue-i18n": "^8.11.2", "vue-property-decorator": "^9.1.2", "vuex": "^3.1.3", "vuex-class": "^0.3.2" @@ -83,7 +84,6 @@ "ts-jest": "^26.0.0", "typescript": "~3.8.3", "vue-cli-plugin-storybook": "~1.2.2", - "vue-i18n": "^8.11.2", "vue-router": "^3.3.4", "vue-template-compiler": "^2.6.11" }, diff --git a/tsconfig.json b/tsconfig.json index 50cc1b58..13d8badd 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -40,6 +40,7 @@ "tests/**/*.tsx" ], "exclude": [ - "node_modules" + "node_modules", + "@soramitsu/soramitsu-js-ui" ] } From 79916230fde9a51f1c4a93f7a13a1183b4b511a2 Mon Sep 17 00:00:00 2001 From: Nikita-Polyakov Date: Wed, 30 Jun 2021 09:12:08 +0300 Subject: [PATCH 07/11] remove i style --- src/styles/neumorphism/button.scss | 13 ------------- tsconfig.json | 3 +-- 2 files changed, 1 insertion(+), 15 deletions(-) diff --git a/src/styles/neumorphism/button.scss b/src/styles/neumorphism/button.scss index b0f9bdb4..a993c5d3 100644 --- a/src/styles/neumorphism/button.scss +++ b/src/styles/neumorphism/button.scss @@ -151,30 +151,17 @@ $neu-button-padding-mini: 3px 6px !default; box-shadow: $neu-button-primary-box-shadow; color: $neu-button-primary-text-color; - i { - color: $neu-button-primary-text-color; - } - &:hover, &:focus, &.focusing { background: $neu-button-primary-background-color-hover; border-color: $neu-button-primary-border-color-hover; color: $neu-button-primary-text-color-hover; box-shadow: $neu-button-primary-box-shadow-hover; - - i { - color: $neu-button-primary-text-color-hover; - } - } &:active, &.s-pressed { background: $neu-button-primary-background-color-pressed; border-color: $neu-button-primary-border-color-pressed; color: $neu-button-primary-text-color-pressed; box-shadow: $neu-button-primary-box-shadow-pressed; - - i { - color: $neu-button-primary-text-color-pressed; - } } @include disabled; diff --git a/tsconfig.json b/tsconfig.json index 13d8badd..50cc1b58 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -40,7 +40,6 @@ "tests/**/*.tsx" ], "exclude": [ - "node_modules", - "@soramitsu/soramitsu-js-ui" + "node_modules" ] } From 28ab8bd1d8e3350df8225502af5b0aee51e4f0c6 Mon Sep 17 00:00:00 2001 From: Nikita-Polyakov Date: Wed, 30 Jun 2021 10:40:40 +0300 Subject: [PATCH 08/11] refactoring --- src/components/Input/SJsonInput.vue | 7 +- src/index.ts | 123 +++++++++++++--------------- src/plugins/index.ts | 1 - src/plugins/jsonUI.ts | 1 - src/stories/SJsonInput.stories.ts | 4 - src/styles/variables.scss | 16 ++-- 6 files changed, 72 insertions(+), 80 deletions(-) delete mode 100644 src/plugins/jsonUI.ts diff --git a/src/components/Input/SJsonInput.vue b/src/components/Input/SJsonInput.vue index 41259f0b..5af0417f 100644 --- a/src/components/Input/SJsonInput.vue +++ b/src/components/Input/SJsonInput.vue @@ -30,8 +30,13 @@