chore: Remove trailing whitespace (#129)

Switch to the convention of using no trailing whitespace, even on blank lines. Also remove some unintended trailing whitespace on non-blank lines and fix a few typos.

Co-authored-by: Aaron Fenyes <aaron.fenyes@fareycircles.ooo>
Reviewed-on: StudioInfinity/dyna3#129
Reviewed-by: Vectornaut <vectornaut@nobody@nowhere.net>
Co-authored-by: Glen Whitney <glen@studioinfinity.org>
Co-committed-by: Glen Whitney <glen@studioinfinity.org>
This commit is contained in:
Glen Whitney 2025-11-11 00:47:40 +00:00 committed by Vectornaut
parent 2c8c09d20d
commit 6c3a48fb52
20 changed files with 335 additions and 340 deletions

View file

@ -21,16 +21,16 @@ fn RegulatorInput(regulator: Rc<dyn Regulator>) -> View {
// get the regulator's measurement and set point signals
let measurement = regulator.measurement();
let set_point = regulator.set_point();
// the `valid` signal tracks whether the last entered value is a valid set
// point specification
let valid = create_signal(true);
// the `value` signal holds the current set point specification
let value = create_signal(
set_point.with_untracked(|set_pt| set_pt.spec.clone())
);
// this `reset_value` closure resets the input value to the regulator's set
// point specification
let reset_value = move || {
@ -39,11 +39,11 @@ fn RegulatorInput(regulator: Rc<dyn Regulator>) -> View {
value.set(set_point.with(|set_pt| set_pt.spec.clone()));
})
};
// reset the input value whenever the regulator's set point specification
// is updated
create_effect(reset_value);
view! {
input(
r#type = "text",
@ -241,7 +241,7 @@ fn ElementOutlineItem(element: Rc<dyn Element>) -> View {
#[component]
pub fn Outline() -> View {
let state = use_context::<AppState>();
// list the elements alphabetically by ID
/* TO DO */
// this code is designed to generalize easily to other sort keys. if we only
@ -254,7 +254,7 @@ pub fn Outline() -> View {
.sorted_by_key(|elt| elt.id().clone())
.collect::<Vec<_>>()
);
view! {
ul(
id = "outline",
@ -272,4 +272,4 @@ pub fn Outline() -> View {
)
}
}
}
}