Browse Source

make input text color $bang-c if query starts with !, fix some css var names

main
familyfriendlymikey 2 years ago
parent
commit
1ad40e8b63
  1. 4
      app/components/app-bang.imba
  2. 2
      app/components/app-community-links.imba
  3. 2
      app/components/app-home.imba
  4. 2
      app/components/app-link.imba
  5. 16
      app/styles.imba

4
app/components/app-bang.imba

@ -96,7 +96,7 @@ tag app-bang
<.bang <.bang
.selected=(state.bang_selection_index is -1) .selected=(state.bang_selection_index is -1)
[c:$bang-color]=(state.bang_selection_index is -1) [c:$bang-c]=(state.bang_selection_index is -1)
@pointerover=(state.bang_selection_index = -1) @pointerover=(state.bang_selection_index = -1)
@click=api.handle_bang @click=api.handle_bang
> >
@ -125,7 +125,7 @@ tag app-bang
<.item <.item
@pointerover=(state.bang_selection_index = index) @pointerover=(state.bang_selection_index = index)
@click=api.handle_bang @click=api.handle_bang
[c:$bang-color]=(state.bang_selection_index is index) [c:$bang-c]=(state.bang_selection_index is index)
.selected=(state.bang_selection_index is index) .selected=(state.bang_selection_index is index)
> item > item
css w:100% fs:17px c:$text-c rd:5px p:10px 10px css w:100% fs:17px c:$text-c rd:5px p:10px 10px

2
app/components/app-community-links.imba

@ -109,7 +109,7 @@ tag app-community-links
py:2px rd:5px cursor:pointer c:$text-c min-height:35px py:2px rd:5px cursor:pointer c:$text-c min-height:35px
if link.is_bang if link.is_bang
css c:$bang-color css c:$bang-c
<.link-left> link.name <.link-left> link.name
css fl:1 css fl:1

2
app/components/app-home.imba

@ -55,6 +55,8 @@ tag app-home
disabled=state.loading disabled=state.loading
@blur=blur @blur=blur
> >
if state.query.startsWith "!"
css c:$bang-c
if (let m = api.math_result) isnt no if (let m = api.math_result) isnt no
<.side.right@click=handle_click_copy(m)> <.side.right@click=handle_click_copy(m)>

2
app/components/app-link.imba

@ -20,7 +20,7 @@ tag app-link
css d:flex fld:row jc:space-between ai:center css d:flex fld:row jc:space-between ai:center
px:16px py:11px rd:5px cursor:pointer c:$text-c px:16px py:11px rd:5px cursor:pointer c:$text-c
if link.is_bang if link.is_bang
css c:$bang-color css c:$bang-c
<.link-left> <.link-left>
css d:flex fl:3 css d:flex fl:3

16
app/styles.imba

@ -5,12 +5,12 @@ global css html
global css .dark global css .dark
$appbg:#20222f $appbg:#20222f
$bodybg:#20222f $bodybg:#20222f
$selected-color:blue3/5 $selected-c:blue3/5
$bang-color:#fad4ab $bang-c:#fad4ab
$text-c:blue3 $text-c:blue3
$input-bg:purple4/10 $input-bg:purple4/10
$input-c:blue3 $input-c:blue3
$input-caret-color:blue3 $input-caret-c:blue3
$input-bc:purple4 $input-bc:purple4
$tip-hotkey-c:purple3/50 $tip-hotkey-c:purple3/50
$tip-content-c:purple3 $tip-content-c:purple3
@ -24,12 +24,12 @@ global css .dark
global css .light global css .light
$bodybg:#ececec $bodybg:#ececec
$appbg:#fff $appbg:#fff
$selected-color:blue5/7 $selected-c:blue5/7
$bang-color:#ff7070 $bang-c:#ff7070
$text-c:#3c3c3c $text-c:#3c3c3c
$input-bg:blue4/10 $input-bg:blue4/10
$input-c:blue3 $input-c:blue3
$input-caret-color:blue3 $input-caret-c:blue3
$input-bc:blue4 $input-bc:blue4
$tip-hotkey-c:blue4/80 $tip-hotkey-c:blue4/80
$tip-content-c:blue5 $tip-content-c:blue5
@ -51,7 +51,7 @@ global css input
bg:$input-bg bg:$input-bg
bc:$input-bc bc:$input-bc
c:$text-c c:$text-c
caret-color:$input-caret-color caret-color:$input-caret-c
global css a global css a
td:none td:none
@ -63,7 +63,7 @@ global css .disabled $main-input
@important bg:gray4/10 bc:gray4 @important bg:gray4/10 bc:gray4
global css .selected global css .selected
bg:$selected-color bg:$selected-c
global css .ellipsis global css .ellipsis
of:hidden text-overflow:ellipsis white-space:nowrap of:hidden text-overflow:ellipsis white-space:nowrap

Loading…
Cancel
Save