anki/ts/components
Matthias Metelka 0c340c4f74
Add comments to Sass variables and tweak main window (#2137)
* Prevent multiple inclusion of variables in CSS files

* Use dict instead of tuple for variables

* Add comments to variables

* Improve appearance of main window

* Tweak main window styles

* Use json.dumps over pprint.format

* Make study button primary

* Improve header margin

* Make bottom toolbar slimmer

* Make congrats page more balanced

* Fix type issue

* Replace day/night with light/dark

* Exclude top-level-drag-row from hover effect

* Create dataclass for variables

* Run formatter

* Apply CSS variables from Python side

Why go full-circle with the Sass variables? This way we only need one interface for add-on authors to interact with. It also makes it easier for us to apply additional themes in the future.

* Fix typing

* Fix rgba values in Qt

* Darken button background

* Fix palette not being applied in light theme

For some odd reason this problem arose much later than #2016.

* Tweak default button look

* Reformat

* Apply CSS vars to ts pages

* Include elevation in button_mixins_lib

* Cast opacity to int

* Add some margin to studiedToday info

* Tweak light theme button gradient

* Tweak highlight-bg for light theme

* Add back default button color

as it made the browser sidebar tool icons dark in light theme.

* Reformat

* Tweak light theme buttons once more

Sorry for the back-and-forth. Sass only compiles when there are changes in user files, not when I only change the vars.

* Fix bottom toolbar button indicators

* Make buttons more clicky

* Fix button padding

* Handle macOS separately again

* Decrease elevation effect for main window buttons to 1

* Imitate box-shadow for Qt elements

* Adjust shadow vars

* Adjust primary border color

because the save button in the deck options had a lighter color than its background gradient.

* Boost box-shadow color of primary buttons

* Format

* Adjust Qt box-shadow imitation and shadow colors

* Use more subtle default shadow color

* Add some more padding to top toolbar

* Revert "Apply CSS vars to ts pages"

This reverts commit 5d8e7f6b7ffc8894b6517ecbb8cfba35407fc69a.

* Revert "Apply CSS variables from Python side"

This reverts commit 87db774412fd2bfd75e2630d2c5e782daef96b5f.

* Better match the standard macOS buttons

In the dark theme the standard color is a lighter grey, but at least
the size/shape is similar again.

This doesn't work for the editor buttons.

* Reduce the top margin of the congrats screen

* Fix illegible buttons when changing theme on macOS; match dark button style
2022-10-29 10:48:53 +10:00
..
Absolute.svelte Translate Editor entirely to Svelte (#1403) 2021-10-18 22:01:15 +10:00
Badge.svelte Insert symbols overlay (#2051) 2022-09-10 18:46:59 +10:00
BUILD.bazel Make tags editor resizable using Henrik's components (#2046) 2022-09-28 14:02:32 +10:00
ButtonGroup.svelte Improved add-on extension API (#1626) 2022-02-03 14:52:11 +10:00
ButtonGroupItem.svelte Use eslint for sorting our imports (#1637) 2022-02-04 18:36:34 +10:00
ButtonToolbar.svelte Improved add-on extension API (#1626) 2022-02-03 14:52:11 +10:00
CheckBox.svelte Move all buttons to our custom inline surrounding (#1682) 2022-02-22 22:17:22 +10:00
Col.svelte Redesign deck options screen, swap tooltips for help modals (#2139) 2022-10-25 16:18:50 +10:00
Collapsible.svelte Finish #2070: Single overlay instead of per field (#2144) 2022-10-27 09:11:36 +10:00
Container.svelte Improved add-on extension API (#1626) 2022-02-03 14:52:11 +10:00
context-keys.ts Live theme changes (#1497) 2021-11-25 07:17:41 +10:00
DropdownDivider.svelte WIP: Use our components in deckoptions sticky bar 2021-05-18 16:32:29 +02:00
DropdownItem.svelte Finish #2070: Single overlay instead of per field (#2144) 2022-10-27 09:11:36 +10:00
DynamicallySlottable.svelte Use eslint for sorting our imports (#1637) 2022-02-04 18:36:34 +10:00
FloatingArrow.svelte fix --frame-bg renamed to --canvas-elevated (#2107) 2022-10-10 13:15:07 +10:00
helpers.ts Use trailingComma: all setting in .prettierrc (#1435) 2021-10-19 09:06:00 +10:00
HorizontalResizer.svelte Make resizer snap to closest end and improve toggle (#2129) 2022-10-13 10:13:19 +10:00
IconButton.svelte Redesign deck options inputs (#2082) 2022-09-27 12:16:45 +10:00
IconConstrain.svelte Redesign deck options inputs (#2082) 2022-09-27 12:16:45 +10:00
icons.ts Make tags editor resizable using Henrik's components (#2046) 2022-09-28 14:02:32 +10:00
Item.svelte Improved add-on extension API (#1626) 2022-02-03 14:52:11 +10:00
LabelButton.svelte Redesign deck options inputs (#2082) 2022-09-27 12:16:45 +10:00
Pane.svelte Make resizer snap to closest end and improve toggle (#2129) 2022-10-13 10:13:19 +10:00
PaneContent.svelte Make tags editor resizable using Henrik's components (#2046) 2022-09-28 14:02:32 +10:00
Popover.svelte Add comments to Sass variables and tweak main window (#2137) 2022-10-29 10:48:53 +10:00
resizable.ts Make tags editor resizable using Henrik's components (#2046) 2022-09-28 14:02:32 +10:00
Row.svelte Improved add-on extension API (#1626) 2022-02-03 14:52:11 +10:00
Select.svelte Add comments to Sass variables and tweak main window (#2137) 2022-10-29 10:48:53 +10:00
SelectOption.svelte Redesign deck options inputs (#2082) 2022-09-27 12:16:45 +10:00
Shortcut.svelte Allow using keyup with registerShortcut (#1755) 2022-03-29 09:28:44 +10:00
Spacer.svelte Space out Sticky Bottom with Spacer component 2021-09-09 15:37:58 +02:00
SpinBox.svelte Add comments to Sass variables and tweak main window (#2137) 2022-10-29 10:48:53 +10:00
StickyContainer.svelte Redesign deck options inputs (#2082) 2022-09-27 12:16:45 +10:00
Switch.svelte Improve hover feedback on various widgets (#2079) 2022-09-20 16:34:15 +10:00
tsconfig.json update to latest rules_nodejs & switch to ts_project 2021-10-01 12:52:53 +10:00
types.ts Make tags editor resizable using Henrik's components (#2046) 2022-09-28 14:02:32 +10:00
VerticalResizer.svelte Make tags editor resizable using Henrik's components (#2046) 2022-09-28 14:02:32 +10:00
WithContext.svelte Use eslint for sorting our imports (#1637) 2022-02-04 18:36:34 +10:00
WithFloating.svelte Set floating shift value to fit area occupied by box-shadow (#2116) 2022-10-10 13:53:13 +10:00
WithOverlay.svelte Redesign deck options inputs (#2082) 2022-09-27 12:16:45 +10:00
WithState.svelte Use WithFloating for MathjaxOverlay (#2011) 2022-09-05 17:20:00 +10:00
WithTooltip.svelte Default input setting in fields dialog (#1987) 2022-08-18 12:30:18 +10:00