Browse Source

introduce new primary color

Falko Schindler 2 years ago
parent
commit
af911169d4
4 changed files with 4 additions and 4 deletions
  1. 1 1
      nicegui/client.py
  2. 1 1
      nicegui/elements/colors.py
  3. 1 1
      website/constants.py
  4. 1 1
      website/example.py

+ 1 - 1
nicegui/client.py

@@ -37,7 +37,7 @@ class Client:
 
         self.waiting_javascript_commands: Dict[str, str] = {}
 
-        self.head_html = ''
+        self.head_html = '<style>body { --q-primary: #5A99FF }</style>'
         self.body_html = ''
 
         self.page = page

+ 1 - 1
nicegui/elements/colors.py

@@ -7,7 +7,7 @@ vue.register_component('colors', __file__, 'colors.js')
 class Colors(Element):
 
     def __init__(self, *,
-                 primary='#1976d2',
+                 primary='#5A99FF',
                  secondary='#26a69a',
                  accent='#9c27b0',
                  positive='#21ba45',

+ 1 - 1
website/constants.py

@@ -1,5 +1,5 @@
 from pathlib import Path
 
-ACCENT_COLOR = '#428BF5'
+ACCENT_COLOR = '#5A99FF'
 HEADER_HEIGHT = '70px'
 STATIC = Path(__file__).parent / 'static'

+ 1 - 1
website/example.py

@@ -59,7 +59,7 @@ class example:
             code = '\n'.join(code)
             with ui.card() \
                     .classes(self.source_classes) \
-                    .style('box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1); background: #ebf0fe'):
+                    .style('box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1); background: #eff5ff'):
                 self._add_dots()
                 ui.markdown(code)
         return f