From a939cb648c291d162c9faba9a3aa21de1ddd1571 Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Mon, 6 Nov 2023 21:22:35 +0100 Subject: [PATCH] [`media` UI] Extracted `PlayPauseButton` into its own component. --- .../webapp/src/components/Media/Controls.vue | 16 +++------ .../src/components/Media/PlayPauseButton.vue | 33 +++++++++++++++++++ .../http/webapp/src/style/themes/light.scss | 1 + 3 files changed, 38 insertions(+), 12 deletions(-) create mode 100644 platypush/backend/http/webapp/src/components/Media/PlayPauseButton.vue diff --git a/platypush/backend/http/webapp/src/components/Media/Controls.vue b/platypush/backend/http/webapp/src/components/Media/Controls.vue index 36db1d624..2692f4714 100644 --- a/platypush/backend/http/webapp/src/components/Media/Controls.vue +++ b/platypush/backend/http/webapp/src/components/Media/Controls.vue @@ -38,11 +38,7 @@
- +
@@ -64,11 +60,7 @@ - + @@ -105,11 +97,12 @@ import Utils from "@/Utils" import MediaUtils from "@/components/Media/Utils"; import ExtraControls from "./ExtraControls"; +import PlayPauseButton from "./PlayPauseButton"; import ProgressBar from "./ProgressBar"; import VolumeSlider from "./VolumeSlider"; export default { - components: {ExtraControls, ProgressBar, VolumeSlider}, + components: {ExtraControls, PlayPauseButton, ProgressBar, VolumeSlider}, mixins: [Utils, MediaUtils], emits: [ 'consume', @@ -316,7 +309,6 @@ button { } .buttons { - height: 50%; margin-bottom: .5em; align-items: center; } diff --git a/platypush/backend/http/webapp/src/components/Media/PlayPauseButton.vue b/platypush/backend/http/webapp/src/components/Media/PlayPauseButton.vue new file mode 100644 index 000000000..7e09efd71 --- /dev/null +++ b/platypush/backend/http/webapp/src/components/Media/PlayPauseButton.vue @@ -0,0 +1,33 @@ + + + + + diff --git a/platypush/backend/http/webapp/src/style/themes/light.scss b/platypush/backend/http/webapp/src/style/themes/light.scss index 4254e270a..427162714 100644 --- a/platypush/backend/http/webapp/src/style/themes/light.scss +++ b/platypush/backend/http/webapp/src/style/themes/light.scss @@ -152,6 +152,7 @@ $input-icon-hover-border: 1px solid rgba(159, 180, 152, 0.83); //// Media elements $play-btn-fg: #27ee5e !default; +$play-btn-hover-fg: #5cfd88 !default; //// Dropdown element $dropdown-bg: rgb(241, 243, 242) !default;