fix: Compiler lints
Gitea Scan/plate-tool/pipeline/head This commit looks good
Details
Gitea Scan/plate-tool/pipeline/head This commit looks good
Details
This commit is contained in:
parent
9aad876a31
commit
83d74cfc6f
|
@ -9,8 +9,6 @@ use crate::components::states::MainState;
|
||||||
|
|
||||||
use super::create_close_button;
|
use super::create_close_button;
|
||||||
|
|
||||||
type NoParamsCallback = Box<dyn Fn(())>;
|
|
||||||
|
|
||||||
pub fn input_json_input_callback(
|
pub fn input_json_input_callback(
|
||||||
main_dispatch: Dispatch<MainState>,
|
main_dispatch: Dispatch<MainState>,
|
||||||
modal: HtmlDialogElement,
|
modal: HtmlDialogElement,
|
||||||
|
|
|
@ -13,8 +13,6 @@ use crate::components::states::{CsvExportType, MainState};
|
||||||
|
|
||||||
use super::create_close_button;
|
use super::create_close_button;
|
||||||
|
|
||||||
type NoParamsCallback = Box<dyn Fn(())>;
|
|
||||||
|
|
||||||
pub fn toggle_in_transfer_hashes_callback(
|
pub fn toggle_in_transfer_hashes_callback(
|
||||||
main_dispatch: Dispatch<MainState>,
|
main_dispatch: Dispatch<MainState>,
|
||||||
) -> Callback<web_sys::MouseEvent> {
|
) -> Callback<web_sys::MouseEvent> {
|
||||||
|
|
|
@ -4,8 +4,6 @@ use wasm_bindgen::{prelude::*, JsCast};
|
||||||
use web_sys::HtmlElement;
|
use web_sys::HtmlElement;
|
||||||
use yew::prelude::*;
|
use yew::prelude::*;
|
||||||
|
|
||||||
type NoParamsCallback = Box<dyn Fn(())>;
|
|
||||||
|
|
||||||
pub fn create_close_button(close: &Closure<dyn FnMut(Event)>) -> HtmlElement {
|
pub fn create_close_button(close: &Closure<dyn FnMut(Event)>) -> HtmlElement {
|
||||||
let document = web_sys::window().unwrap().document().unwrap();
|
let document = web_sys::window().unwrap().document().unwrap();
|
||||||
let close_button = document
|
let close_button = document
|
||||||
|
|
|
@ -17,7 +17,9 @@ pub struct NewPlateDialogProps {
|
||||||
pub enum NewPlateDialogType {
|
pub enum NewPlateDialogType {
|
||||||
SourceOnly,
|
SourceOnly,
|
||||||
DestinationOnly,
|
DestinationOnly,
|
||||||
Both,
|
|
||||||
|
#[allow(dead_code)]
|
||||||
|
Both, // Retained old functionality
|
||||||
}
|
}
|
||||||
|
|
||||||
#[function_component]
|
#[function_component]
|
||||||
|
|
|
@ -26,6 +26,7 @@ impl ColorPalette {
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[allow(dead_code)] // Preserve old implementation for reference
|
||||||
fn get_u8(&self, t: u8) -> [f64; 3] {
|
fn get_u8(&self, t: u8) -> [f64; 3] {
|
||||||
assert!(t > 0, "t must be greater than zero!");
|
assert!(t > 0, "t must be greater than zero!");
|
||||||
self.get((2f64.powi(-(t.ilog2() as i32))) * (t as f64 + 0.5f64) - 1.0f64)
|
self.get((2f64.powi(-(t.ilog2() as i32))) * (t as f64 + 0.5f64) - 1.0f64)
|
||||||
|
|
Loading…
Reference in New Issue