Better disabled textbox style
This commit is contained in:
@@ -465,4 +465,11 @@
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
padding: 0.5em; */
|
padding: 0.5em; */
|
||||||
|
}
|
||||||
|
|
||||||
|
:global(input[type=text]:disabled) {
|
||||||
|
@include disable-input;
|
||||||
|
}
|
||||||
|
:global(textarea:disabled) {
|
||||||
|
@include disable-input;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -126,6 +126,9 @@
|
|||||||
|
|
||||||
:global(input[type=number]) {
|
:global(input[type=number]) {
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
|
&:disabled {
|
||||||
|
@include disable-input;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&.mobile {
|
&.mobile {
|
||||||
|
|||||||
@@ -46,10 +46,17 @@
|
|||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<style>
|
<style lang="scss">
|
||||||
.wrapper {
|
.wrapper {
|
||||||
padding: 2px;
|
padding: 2px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|
||||||
|
:global(input[type=text]:disabled) {
|
||||||
|
@include disable-input;
|
||||||
|
}
|
||||||
|
:global(textarea:disabled) {
|
||||||
|
@include disable-input;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
:global(span.hide) {
|
:global(span.hide) {
|
||||||
|
|||||||
@@ -10,3 +10,11 @@ body {
|
|||||||
:root {
|
:root {
|
||||||
--color-blue-500: #3985f5;
|
--color-blue-500: #3985f5;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@mixin disable-input {
|
||||||
|
-webkit-text-fill-color: var(--neutral-500);
|
||||||
|
background-color: var(--neutral-200);
|
||||||
|
border-color: var(--neutral-300);
|
||||||
|
box-shadow: 0 0 0 var(--shadow-spread) transparent, rgba(0, 0, 0, 0.08) 0px 2px 4px 0px inset;
|
||||||
|
cursor: not-allowed;
|
||||||
|
}
|
||||||
|
|||||||
@@ -76,6 +76,7 @@ License: GNU General Public License
|
|||||||
--ae-nav-color:hsl(210deg 4% 80%);
|
--ae-nav-color:hsl(210deg 4% 80%);
|
||||||
--ae-nav-hover-color:hsl(0deg 0% 4%);
|
--ae-nav-hover-color:hsl(0deg 0% 4%);
|
||||||
--ae-input-color:hsl(210deg 4% 80%);
|
--ae-input-color:hsl(210deg 4% 80%);
|
||||||
|
--ae-input-disabled-color:hsl(210deg 4% 40%);
|
||||||
--ae-label-color:hsl(210deg 4% 80%);
|
--ae-label-color:hsl(210deg 4% 80%);
|
||||||
--ae-subgroup-input-color:hsl(0deg 100% 100%);
|
--ae-subgroup-input-color:hsl(0deg 100% 100%);
|
||||||
--ae-placeholder-color:hsl(214deg 5% 30%);
|
--ae-placeholder-color:hsl(214deg 5% 30%);
|
||||||
@@ -463,6 +464,10 @@ select {
|
|||||||
min-width: unset;
|
min-width: unset;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
input:disabled, textarea:disabled {
|
||||||
|
-webkit-text-fill-color: var(--ae-input-disabled-color) !important;
|
||||||
|
}
|
||||||
|
|
||||||
select {
|
select {
|
||||||
appearance: auto;
|
appearance: auto;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,9 @@
|
|||||||
import sveltePreprocess from "svelte-preprocess";
|
import sveltePreprocess from "svelte-preprocess";
|
||||||
|
import path, { dirname } from 'path'
|
||||||
|
import { fileURLToPath } from 'url'
|
||||||
|
|
||||||
|
const filePath = dirname(fileURLToPath(import.meta.url))
|
||||||
|
const scssPath = `./src/scss`
|
||||||
|
|
||||||
const config = {
|
const config = {
|
||||||
preprocess: [
|
preprocess: [
|
||||||
@@ -8,6 +13,9 @@ const config = {
|
|||||||
debug: true,
|
debug: true,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
scss: {
|
||||||
|
prependData: `@import '${scssPath}/global.scss';`
|
||||||
|
}
|
||||||
})
|
})
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user