-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GenieBuilder -> DataTable -> Style -> Color not working #108
Comments
It does change the color, but you are probably looking at the wrong part of the table. The color property changes the color of the pagination buttons, but you would need to omit the colon before <q-table :data="data.data" :pagination="data_pagination" :columns="data.columns" color="primary"></q-table> If you want to change the color of the lines you need to change the attribute <q-table :data="data.data" :pagination="data_pagination" :columns="data.columns" table-class="bg-primary"></q-table> or via StippleUI: table(:data, table__class = "bg-primary") Theroretically, you would also be able to set the font color here by setting .stipple-core .q-table tbody tr {
color: var(--st-text-2);
} @essenciary We should somehow release that restriction without breaking our current layouts. Any idea? |
Currently the only way is probably to overload the critical definition from stipple-core.css function add_css(css::Function; update = true)
update && deleteat!(Stipple.Layout.THEMES, nameof.(Stipple.Layout.THEMES) .== nameof(css))
push!(Stipple.Layout.THEMES, css)
end
function mycss()
[style("""
.stipple-core .q-table tbody tr { color: inherit; }
""")]
end
add_css(mycss) |
@essenciary Shouldn't we add |
@hhaensel Yes, looks good |
@Atitlanio function mycss()
[style("""
.stipple-core .q-table tbody tr { color: inherit; }
""")]
end
add_css(mycss) Then you can style your table by the |
The
Color
property of aDataTable
doesn't seem to have any effect. E.g., setting it to "primary"Steps to Reproduce:
DataTable
blockData Binding
,Columns
andPagination
Style
->Color
toprimary
app.jl.html
has the following:<q-table :data="data.data" :pagination="data_pagination" :columns="data.columns" :color="primary"></q-table>
Color remains the default white. Tried other values such as
warning
,red-8
,blue
, etc.Temporary working solution is to set
Table Style
='background-color: #XXXXXX'
, e.g.,<q-table :data="in_data.data" :pagination="data_pagination" :columns="in_data.columns" :dense="true" :table-style="'background-color: #99a0fc'"></q-table>
The text was updated successfully, but these errors were encountered: