mirror of
https://github.com/1j01/textual-paint.git
synced 2024-12-21 22:01:31 +03:00
Use a shared CSS class for styling Open/Save As dialogs
This commit is contained in:
parent
5b20caf118
commit
2a2b29e30e
12
paint.css
12
paint.css
@ -197,24 +197,20 @@ Screen {
|
||||
background: $surface;
|
||||
}
|
||||
|
||||
#save_as_dialog .window_content,
|
||||
#open_dialog .window_content {
|
||||
.file_dialog_window .window_content {
|
||||
padding: 2 4;
|
||||
width: 80;
|
||||
height: 30;
|
||||
}
|
||||
#save_as_dialog .window_content Input,
|
||||
#open_dialog .window_content Input {
|
||||
.file_dialog_window .window_content Input {
|
||||
width: 100%;
|
||||
margin-bottom: 1;
|
||||
}
|
||||
#save_as_dialog .window_content DirectoryTree,
|
||||
#open_dialog .window_content DirectoryTree {
|
||||
.file_dialog_window .window_content DirectoryTree {
|
||||
height: 15;
|
||||
margin-bottom: 1;
|
||||
}
|
||||
#save_as_dialog .window_content Button,
|
||||
#open_dialog .window_content Button {
|
||||
.file_dialog_window .window_content Button {
|
||||
width: auto;
|
||||
height: auto;
|
||||
}
|
||||
|
2
paint.py
2
paint.py
@ -1039,6 +1039,7 @@ class PaintApp(App):
|
||||
|
||||
window = DialogWindow(
|
||||
id="save_as_dialog",
|
||||
classes="file_dialog_window",
|
||||
title=_("Save As"),
|
||||
handle_button=handle_button,
|
||||
)
|
||||
@ -1282,6 +1283,7 @@ class PaintApp(App):
|
||||
old_window.close()
|
||||
window = DialogWindow(
|
||||
id="open_dialog",
|
||||
classes="file_dialog_window",
|
||||
title=_("Open"),
|
||||
handle_button=handle_button,
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user