-
Notifications
You must be signed in to change notification settings - Fork 92
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
Update @render.data_frame
renderer to work properly with fill/fillable
#1126
Conversation
f28a77d
to
3074eee
Compare
Overall this looks great! Only regressing case I could find is import seaborn as sns
from shiny.express import render, ui
df = sns.load_dataset("iris").iloc[:5,]
@render.data_frame
def data_frame():
return render.DataGrid(
df,
height="auto",
)
with ui.p():
"Hello" |
I also noticed that even on main, |
87daed7
to
fd0c940
Compare
Agreed (and I don't think so) in general, but it's maybe worth doing inside a card? 87daed7 restricts it to just a
Oops, that's cause of the
I don't think this is a problem, at least for the situation you're thinking of. It could be a problem though if the children of that element are for some reason not compatible with a Just to illustrate, here's the example you have in mind, with the result (which seems right): import seaborn as sns
from shiny.express import render, ui
df = sns.load_dataset("iris").iloc[:5,]
with ui.card(height="400px"):
@render.data_frame
def data_frame():
return render.DataGrid(df, height="auto")
with ui.p():
"Hello" ![]() |
We can merge without that fix though, if you don't think there's anything we can do about it right now. |
Ah, good point. 789147c addresses that. |
Oh, interesting approach! Great. Still feels weird to me that it's centered, but like you, I could be talked into it. Have you run this by Garrick or Greg? |
@gregswinehart "loves it" :) |
OK, I'm happy to be overruled! |
* main: Update `@render.data_frame` renderer to work properly with fill/fillable (#1126) Don't error on malformed date input (#1139) fix(nav_panel): Add `.bslib-gap-spacing` if nav panel is fillable (#1154) feat: Add `ui.input_dark_mode()` (#1149) chore(make): Add `make docs` and `make docs-preview` (#1150) Sync with latest bslib sidebar and card changes (#1129) docs(input_task_button): Add to reference index, also update methods for action button/link (#1151) chore(make): Update check and check-fix to replicate CI (#1148)
Closes #1118