Skip to content

Commit

Permalink
Merge pull request #67 from Zaseem-BIsquared/main
Browse files Browse the repository at this point in the history
Update component classes to align with Franken UI v2.0
  • Loading branch information
Isaac-Flath authored Feb 12, 2025
2 parents 056311d + c9ff30c commit 417e0dd
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 16 deletions.
2 changes: 2 additions & 0 deletions monsterui/_modidx.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@
'monsterui.franken.CodeSpan': ('franken.html#codespan', 'monsterui/franken.py'),
'monsterui.franken.Container': ('franken.html#container', 'monsterui/franken.py'),
'monsterui.franken.ContainerT': ('franken.html#containert', 'monsterui/franken.py'),
'monsterui.franken.ContainerT._generate_next_value_': ( 'franken.html#containert._generate_next_value_',
'monsterui/franken.py'),
'monsterui.franken.Data': ('franken.html#data', 'monsterui/franken.py'),
'monsterui.franken.Del': ('franken.html#del', 'monsterui/franken.py'),
'monsterui.franken.Details': ('franken.html#details', 'monsterui/franken.py'),
Expand Down
17 changes: 9 additions & 8 deletions monsterui/franken.py
Original file line number Diff line number Diff line change
Expand Up @@ -413,11 +413,12 @@ def Button(*c: Union[str, FT], # Contents of `Button` tag (often text)
# %% ../nbs/02_franken.ipynb
class ContainerT(VEnum):
'Max width container sizes from https://franken-ui.dev/docs/container'
xs = 'uk-container-xsmall'
sm = 'uk-container-small'
lg = 'uk-container-large'
xl = 'uk-container-xlarge'
expand = 'uk-container-expand'
def _generate_next_value_(name, start, count, last_values): return str2ukcls('container', name)
xs = auto()
sm = auto()
lg = auto()
xl = auto()
expand = auto()

# %% ../nbs/02_franken.ipynb
class BackgroundT(VEnum):
Expand Down Expand Up @@ -1296,7 +1297,7 @@ def _generate_next_value_(name, start, count, last_values): return str2ukcls('ca
default = auto()
primary = auto()
secondary = auto()
danger = auto()
destructive = auto()
hover = 'uk-card hover:shadow-lg hover:-translate-y-1 transition-all duration-200'

# %% ../nbs/02_franken.ipynb
Expand Down Expand Up @@ -1359,8 +1360,8 @@ def _generate_next_value_(name, start, count, last_values): return str2ukcls('ta
divider = auto()
striped = auto()
hover = auto()
sm = 'uk-table-small'
lg = 'uk-table-large'
sm = auto()
lg = auto()
justify = auto()
middle = auto()
responsive = auto()
Expand Down
17 changes: 9 additions & 8 deletions nbs/02_franken.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -725,11 +725,12 @@
"#| export\n",
"class ContainerT(VEnum):\n",
" 'Max width container sizes from https://franken-ui.dev/docs/container'\n",
" xs = 'uk-container-xsmall'\n",
" sm = 'uk-container-small'\n",
" lg = 'uk-container-large'\n",
" xl = 'uk-container-xlarge'\n",
" expand = 'uk-container-expand'"
" def _generate_next_value_(name, start, count, last_values): return str2ukcls('container', name)\n",
" xs = auto()\n",
" sm = auto()\n",
" lg = auto()\n",
" xl = auto()\n",
" expand = auto()"
]
},
{
Expand Down Expand Up @@ -2557,7 +2558,7 @@
" default = auto()\n",
" primary = auto()\n",
" secondary = auto()\n",
" danger = auto()\n",
" destructive = auto()\n",
" hover = 'uk-card hover:shadow-lg hover:-translate-y-1 transition-all duration-200'"
]
},
Expand Down Expand Up @@ -2652,8 +2653,8 @@
" divider = auto()\n",
" striped = auto()\n",
" hover = auto()\n",
" sm = 'uk-table-small'\n",
" lg = 'uk-table-large'\n",
" sm = auto()\n",
" lg = auto()\n",
" justify = auto()\n",
" middle = auto()\n",
" responsive = auto()"
Expand Down

0 comments on commit 417e0dd

Please sign in to comment.