Release preparation for forms #55

Merged
BobdaFett merged 8 commits from ci/remove-debug-info into main 2026-01-17 04:18:48 +00:00
4 changed files with 33 additions and 25 deletions
Showing only changes of commit 0b2dc1b0c1 - Show all commits

No files matched your search

+1 -1
View File
@@ -8,7 +8,7 @@ pub fn ActionButton(
) -> impl IntoView { ) -> impl IntoView {
view! { view! {
<button <button
class="m-1.5 p-2.5 rounded-lg font-semibold text-white transition-all duration-400 cursor-pointer" class="m-1.5 p-2.5 min-w-20 rounded-lg font-semibold text-white transition-all duration-400 cursor-pointer"
class=(["bg-red-800", "hover:bg-red-900"], move || !disabled.get()) class=(["bg-red-800", "hover:bg-red-900"], move || !disabled.get())
class=(["bg-gray-600", "pointer-events-none"], move || disabled.get()) class=(["bg-gray-600", "pointer-events-none"], move || disabled.get())
r#type=button_type r#type=button_type
+2 -2
View File
@@ -31,7 +31,7 @@ pub fn Radio(
/> />
// This div displays the box for the checkbox, and applies some styling to the child // This div displays the box for the checkbox, and applies some styling to the child
// span element. // span element.
<div class="relative inline-block h-5 w-5 m-1 mr-2 rounded-full border border-gray-300 bg-white <div class="relative inline-block h-5 w-5 m-1 mr-2 rounded-full border border-gray-400 bg-white
transition-bg duration-200 peer-checked:bg-red-700 peer-checked:border-red-700 transition-bg duration-200 peer-checked:bg-red-700 peer-checked:border-red-700
[&>span]:opacity-0 peer-checked:[&>span]:opacity-100 [&>span]:opacity-0 peer-checked:[&>span]:opacity-100
peer-disabled:bg-gray-600/33 peer-disabled:border-gray-600 peer-disabled:bg-gray-600/33 peer-disabled:border-gray-600
@@ -107,7 +107,7 @@ fn RadioOther(
/> />
// This div displays the box for the checkbox, and applies some styling to the child // This div displays the box for the checkbox, and applies some styling to the child
// span element. // span element.
<div class="relative inline-block min-h-5 min-w-5 h-5 w-5 m-1 mr-2 rounded-full border border-gray-300 bg-white <div class="relative inline-block min-h-5 min-w-5 h-5 w-5 m-1 mr-2 rounded-full border border-gray-400 bg-white
transition-bg duration-200 peer-checked:bg-red-700 peer-checked:border-red-700 transition-bg duration-200 peer-checked:bg-red-700 peer-checked:border-red-700
[&>span]:opacity-0 peer-checked:[&>span]:opacity-100 [&>span]:opacity-0 peer-checked:[&>span]:opacity-100
peer-disabled:bg-gray-600/33 peer-disabled:border-gray-600 peer-disabled:bg-gray-600/33 peer-disabled:border-gray-600
+1 -1
View File
@@ -31,7 +31,7 @@ pub fn AuthCallbackPage() -> impl IntoView {
view! { view! {
<div class="flex flex-col w-full mx-auto items-center justify-center"> <div class="flex flex-col w-full mx-auto items-center justify-center">
<p>"Completing the login process..."</p> <p class="text-xl font-bold mt-10 mx-auto">"Logging you in..."</p>
</div> </div>
} }
} }
+29 -21
View File
@@ -175,10 +175,27 @@ fn ScholarshipList(
} }
}); });
let modal_on_click_continue = move |_| {
let subject = pending_delete
.get()
.map(|s| s.subject.clone())
.unwrap_or_default();
log!("Deleting scholarship with subject {}", subject);
delete_action
.dispatch(DeleteProviderScholarship {
scholarship_id: subject,
provider_id: provider_id.get().unwrap_or_default(),
});
};
view! { view! {
<dialog node_ref=delete_dialog_ref class="m-auto p-2"> <dialog
node_ref=delete_dialog_ref
class="m-auto p-5 rounded-lg shadow-xl/50
backdrop:backdrop-blur-xs backdrop:transition-backdrop-filter"
>
<h2 class="text-2xl font-bold">"Confirm Deletion"</h2> <h2 class="text-2xl font-bold">"Confirm Deletion"</h2>
<p> <p class="mb-3">
"Are you sure you want to delete " "Are you sure you want to delete "
{move || { {move || {
pending_delete pending_delete
@@ -189,28 +206,16 @@ fn ScholarshipList(
.unwrap_or(&ValueType::String(None)) .unwrap_or(&ValueType::String(None))
.as_string() .as_string()
.unwrap_or_default() .unwrap_or_default()
.unwrap_or("<no name found>".to_string()) .unwrap_or("this unnamed scholarship".to_string())
}) })
}} "?" }} "?"
</p> </p>
<ActionButton <div class="flex mx-auto items-center justify-center">
on:click=move |_| { <ActionButton on:click=modal_on_click_continue disabled=modal_disabled>
let subject = pending_delete "Yes"
.get() </ActionButton>
.map(|s| s.subject.clone()) <ActionButton on:click=move |_| pending_delete.set(None)>"No"</ActionButton>
.unwrap_or_default(); </div>
log!("Deleting scholarship with subject {}", subject);
delete_action
.dispatch(DeleteProviderScholarship {
scholarship_id: subject,
provider_id: provider_id.get().unwrap_or_default(),
});
}
disabled=modal_disabled
>
"Confirm"
</ActionButton>
<ActionButton on:click=move |_| pending_delete.set(None)>"Cancel"</ActionButton>
</dialog> </dialog>
<div class="w-75"> <div class="w-75">
<Panel> <Panel>
@@ -631,6 +636,7 @@ fn ScholarshipForm(
data_map=chips_data data_map=chips_data
values=gpa_ids values=gpa_ids
displayed_text=gpa_text displayed_text=gpa_text
allows_multiple=false
/> />
</Row> </Row>
<Row> <Row>
@@ -649,6 +655,7 @@ fn ScholarshipForm(
data_map=chips_data data_map=chips_data
values=comm_ids values=comm_ids
displayed_text=comm_text displayed_text=comm_text
allows_multiple=false
/> />
</Row> </Row>
<Row> <Row>
@@ -658,6 +665,7 @@ fn ScholarshipForm(
data_map=chips_data data_map=chips_data
values=res_ids values=res_ids
displayed_text=res_text displayed_text=res_text
allows_multiple=false
/> />
</Row> </Row>
<Row> <Row>