Skip to content

Commit aec9103

Browse files
authored
fix: radio background color / inline gap (#947)
1 parent 4854618 commit aec9103

File tree

4 files changed

+14
-3
lines changed

4 files changed

+14
-3
lines changed

src/unfold/static/unfold/css/styles.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/unfold/templates/unfold/widgets/radio.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{% with id=widget.attrs.id %}
2-
<div{% if id %} id="{{ id }}"{% endif %} class="flex gap-2 {% if radio_style == 1 %} flex-row{% else %} flex-col{% endif %}">
2+
<div{% if id %} id="{{ id }}"{% endif %} class="flex gap-2 {% if radio_style == 1 %} flex-row gap-4{% else %} flex-col{% endif %}">
33
{% for group, options, index in widget.optgroups %}
44
{% if group %}
55
<div>

src/unfold/widgets.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,8 @@
223223
"checked:border-primary-600",
224224
"checked:transition-all",
225225
"checked:after:bg-white",
226-
"checked:after:dark:bg-base-200",
226+
"checked:after:dark:bg-base-900",
227+
"checked:hover:border-base-900/20",
227228
]
228229

229230
SWITCH_CLASSES = [

tailwind.config.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,19 @@ module.exports = {
8888
},
8989
plugins: [require("@tailwindcss/typography")],
9090
safelist: [
91+
"border-2",
92+
"border-base-300",
93+
"border-base-400",
94+
"dark:border-base-500",
9195
"border-l",
96+
"border-b-0",
97+
"border-l-0",
98+
"border-r-0",
99+
"border-t-0",
92100
"flex-grow",
93101
"pb-0",
102+
"h-3",
103+
"w-3",
94104
"w-96",
95105
"max-w-96",
96106
"md:border-0",

0 commit comments

Comments
 (0)