summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorpml68 <contact@pml68.dev>2025-06-26 12:16:52 +0200
committerpml68 <contact@pml68.dev>2025-06-26 12:16:52 +0200
commit00c6cf80cb9c4587700078a062a6b32873b6f8ff (patch)
tree9aad054c784b51d4a0bc97c928b89da7dbcab863 /src
parentfeat: update for hot reloading support (diff)
downloadiced-builder-00c6cf80cb9c4587700078a062a6b32873b6f8ff.tar.gz
feat: extract `material_theme` into separate repo (`pml68/iced_material`)
Diffstat (limited to 'src')
-rw-r--r--src/appearance.rs2
-rw-r--r--src/config.rs2
-rw-r--r--src/dialog.rs2
-rw-r--r--src/main.rs2
-rw-r--r--src/panes/code_view.rs8
-rw-r--r--src/panes/designer_view.rs2
-rw-r--r--src/panes/element_list.rs2
-rw-r--r--src/panes/style.rs2
-rw-r--r--src/types.rs2
-rw-r--r--src/widget.rs4
10 files changed, 14 insertions, 14 deletions
diff --git a/src/appearance.rs b/src/appearance.rs
index 78e782d..4d73ec5 100644
--- a/src/appearance.rs
+++ b/src/appearance.rs
@@ -1,6 +1,6 @@
use std::sync::Arc;
-use material_theme::Theme;
+use iced_material::Theme;
pub fn iced_theme_from_str(theme_name: &str) -> iced::Theme {
match theme_name {
diff --git a/src/config.rs b/src/config.rs
index 537cf66..0ef094c 100644
--- a/src/config.rs
+++ b/src/config.rs
@@ -4,7 +4,7 @@
use std::path::{Path, PathBuf};
use std::sync::Arc;
-use material_theme::Theme;
+use iced_material::Theme;
use serde::{Deserialize, Serialize};
use tokio_stream::StreamExt;
use tokio_stream::wrappers::ReadDirStream;
diff --git a/src/dialog.rs b/src/dialog.rs
index 68bbd6e..d5fdc14 100644
--- a/src/dialog.rs
+++ b/src/dialog.rs
@@ -91,7 +91,7 @@ impl Dialog {
pub fn as_iced_dialog<'a>(
&'a self,
base: impl Into<Element<'a, Message>>,
- ) -> iced_dialog::Dialog<'a, Message, material_theme::Theme> {
+ ) -> iced_dialog::Dialog<'a, Message, iced_material::Theme> {
iced_dialog::Dialog::with_buttons(
self.is_open,
base,
diff --git a/src/main.rs b/src/main.rs
index 6d9e5a4..545f176 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -25,7 +25,7 @@ use iced::{
};
use iced_anim::transition::Easing;
use iced_anim::{Animated, Animation};
-use material_theme::Theme;
+use iced_material::Theme;
use panes::{code_view, designer_view, element_list};
use types::{
Action, ConfigChangeType, DesignerPane, Element, Message, Panes, Project,
diff --git a/src/panes/code_view.rs b/src/panes/code_view.rs
index b7aa760..daef547 100644
--- a/src/panes/code_view.rs
+++ b/src/panes/code_view.rs
@@ -3,7 +3,7 @@ use iced::border::Radius;
use iced::widget::{button, pane_grid, row, text, text_editor};
use iced::{Alignment, Border, Font, Length};
use iced_custom_highlighter::{Highlight, Highlighter, Scope, Settings};
-use material_theme::Theme;
+use iced_material::Theme;
use super::style;
use crate::icon;
@@ -38,7 +38,7 @@ pub fn view(
button(icon::copy())
.on_press(Message::CopyCode)
.padding([2, 7])
- .style(material_theme::button::text),
+ .style(iced_material::button::text),
"Copy",
tip::Position::FollowCursor
),
@@ -52,7 +52,7 @@ pub fn view(
button(icon::copy())
.on_press(Message::CopyCode)
.padding([2, 7])
- .style(material_theme::button::text),
+ .style(iced_material::button::text),
"Copy",
tip::Position::FollowCursor
),
@@ -74,7 +74,7 @@ pub fn view(
Highlight::to_format,
)
.style(|theme, _| {
- let style = material_theme::text_editor::default(
+ let style = iced_material::text_editor::default(
theme,
text_editor::Status::Active,
);
diff --git a/src/panes/designer_view.rs b/src/panes/designer_view.rs
index 1525993..c4812c5 100644
--- a/src/panes/designer_view.rs
+++ b/src/panes/designer_view.rs
@@ -2,7 +2,7 @@ use iced::widget::{
button, center, container, pane_grid, responsive, row, text, themer,
};
use iced::{Alignment, Length};
-use material_theme::Theme;
+use iced_material::Theme;
use super::style;
use crate::icon;
diff --git a/src/panes/element_list.rs b/src/panes/element_list.rs
index 0e5dbfe..5e7d99d 100644
--- a/src/panes/element_list.rs
+++ b/src/panes/element_list.rs
@@ -1,7 +1,7 @@
use iced::widget::{Column, column, container, pane_grid, text};
use iced::{Alignment, Length};
use iced_drop::droppable;
-use material_theme::Theme;
+use iced_material::Theme;
use super::style;
use crate::types::{Element, ElementName, Message};
diff --git a/src/panes/style.rs b/src/panes/style.rs
index acca6f9..df21a04 100644
--- a/src/panes/style.rs
+++ b/src/panes/style.rs
@@ -1,6 +1,6 @@
use iced::widget::container::Style;
use iced::{Background, Border};
-use material_theme::Theme;
+use iced_material::Theme;
pub fn title_bar(theme: &Theme) -> Style {
let surface = theme.colors().surface;
diff --git a/src/types.rs b/src/types.rs
index 64f10d0..eb3028d 100644
--- a/src/types.rs
+++ b/src/types.rs
@@ -9,7 +9,7 @@ use iced::advanced::widget::Id;
use iced::widget::{pane_grid, text_editor};
use iced::window;
use iced_anim::Event;
-use material_theme::Theme;
+use iced_material::Theme;
pub use project::Project;
pub use rendered_element::*;
diff --git a/src/widget.rs b/src/widget.rs
index 859d25e..5ebe1f9 100644
--- a/src/widget.rs
+++ b/src/widget.rs
@@ -1,5 +1,5 @@
use iced::widget::{self, container, text, tooltip};
-use material_theme::Theme;
+use iced_material::Theme;
use crate::types::Element;
@@ -15,7 +15,7 @@ pub fn tip<'a, Message: 'a>(
tooltip(
target,
container(text(tip).size(14)).padding(5).style(|theme| {
- let base = material_theme::container::surface_container_low(theme);
+ let base = iced_material::container::surface_container_low(theme);
container::Style {
border: iced::border::rounded(4),
..base