Remove Clone bound for HighlightedLabel

This commit is contained in:
Marshall Bowers 2023-10-19 16:34:08 -04:00
parent 3ac7ef90ef
commit fa3916d1bf
2 changed files with 7 additions and 7 deletions

View File

@ -122,11 +122,11 @@ mod stories {
use super::*; use super::*;
#[derive(Element)] #[derive(Element)]
pub struct InputStory<S: 'static + Send + Sync + Clone> { pub struct InputStory<S: 'static + Send + Sync> {
state_type: PhantomData<S>, state_type: PhantomData<S>,
} }
impl<S: 'static + Send + Sync + Clone> InputStory<S> { impl<S: 'static + Send + Sync> InputStory<S> {
pub fn new() -> Self { pub fn new() -> Self {
Self { Self {
state_type: PhantomData, state_type: PhantomData,

View File

@ -107,8 +107,8 @@ impl<S: 'static + Send + Sync> Label<S> {
} }
} }
#[derive(Element, Clone)] #[derive(Element)]
pub struct HighlightedLabel<S: 'static + Send + Sync + Clone> { pub struct HighlightedLabel<S: 'static + Send + Sync> {
state_type: PhantomData<S>, state_type: PhantomData<S>,
label: SharedString, label: SharedString,
color: LabelColor, color: LabelColor,
@ -116,7 +116,7 @@ pub struct HighlightedLabel<S: 'static + Send + Sync + Clone> {
strikethrough: bool, strikethrough: bool,
} }
impl<S: 'static + Send + Sync + Clone> HighlightedLabel<S> { impl<S: 'static + Send + Sync> HighlightedLabel<S> {
pub fn new(label: impl Into<SharedString>, highlight_indices: Vec<usize>) -> Self { pub fn new(label: impl Into<SharedString>, highlight_indices: Vec<usize>) -> Self {
Self { Self {
state_type: PhantomData, state_type: PhantomData,
@ -214,11 +214,11 @@ mod stories {
use super::*; use super::*;
#[derive(Element)] #[derive(Element)]
pub struct LabelStory<S: 'static + Send + Sync + Clone> { pub struct LabelStory<S: 'static + Send + Sync> {
state_type: PhantomData<S>, state_type: PhantomData<S>,
} }
impl<S: 'static + Send + Sync + Clone> LabelStory<S> { impl<S: 'static + Send + Sync> LabelStory<S> {
pub fn new() -> Self { pub fn new() -> Self {
Self { Self {
state_type: PhantomData, state_type: PhantomData,