Remove dummy components
This commit is contained in:
parent
98038944f2
commit
303831bda3
|
@ -1,6 +1,7 @@
|
||||||
div.plate_container {
|
div.plate_container {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
justify-content: space-around;
|
||||||
align-items: flex-end;
|
align-items: flex-end;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -25,8 +25,6 @@ pub fn SourcePlate(cx: Scope<SourcePlateProps>) -> Element {
|
||||||
div{
|
div{
|
||||||
class: "source_plate",
|
class: "source_plate",
|
||||||
style { STYLE }
|
style { STYLE }
|
||||||
SourcePlateSelectionIndicator {}
|
|
||||||
SourcePlateSelectionController {}
|
|
||||||
table {
|
table {
|
||||||
draggable: "false",
|
draggable: "false",
|
||||||
for i in 1..=cx.props.height {
|
for i in 1..=cx.props.height {
|
||||||
|
@ -98,33 +96,6 @@ fn in_rect(corner1: Option<(u8, u8)>, corner2: Option<(u8, u8)>, pt: (u8, u8)) -
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// This is a dummy component for design purposes only
|
|
||||||
fn SourcePlateSelectionIndicator(cx: Scope) -> Element {
|
|
||||||
let selection_state = use_shared_state::<SelectionState>(cx).unwrap();
|
|
||||||
let start_str = match selection_state.read().m_start {
|
|
||||||
Some(start) => format!("{},{}", start.0, start.1),
|
|
||||||
None => "None".to_string(),
|
|
||||||
};
|
|
||||||
let end_str = match selection_state.read().m_end {
|
|
||||||
Some(end) => format!("{},{}", end.0, end.1),
|
|
||||||
None => "None".to_string(),
|
|
||||||
};
|
|
||||||
|
|
||||||
cx.render(rsx! {
|
|
||||||
p { start_str ", and " end_str }
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
fn SourcePlateSelectionController(cx: Scope) -> Element {
|
|
||||||
cx.render(rsx! {
|
|
||||||
div {
|
|
||||||
button {
|
|
||||||
"Select"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests {
|
mod tests {
|
||||||
use super::in_rect;
|
use super::in_rect;
|
||||||
|
|
Loading…
Reference in New Issue