-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[IMP] web_widget_progressbar_color: Rename to web_widget_progressbar_…
…gradient
- Loading branch information
1 parent
9289bc8
commit d09b4aa
Showing
20 changed files
with
72 additions
and
58 deletions.
There are no files selected for viewing
1 change: 0 additions & 1 deletion
1
setup/web_widget_progressbar_color/odoo/addons/web_widget_progressbar_color
This file was deleted.
Oops, something went wrong.
1 change: 1 addition & 0 deletions
1
setup/web_widget_progressbar_gradient/odoo/addons/web_widget_progressbar_gradient
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../../web_widget_progressbar_gradient |
File renamed without changes.
This file was deleted.
Oops, something went wrong.
Binary file removed
BIN
-4.76 KB
web_widget_progressbar_color/static/description/progressbar_color.png
Binary file not shown.
11 changes: 0 additions & 11 deletions
11
web_widget_progressbar_color/static/src/js/progressbar.esm.js
This file was deleted.
Oops, something went wrong.
12 changes: 0 additions & 12 deletions
12
web_widget_progressbar_color/static/src/scss/progressbar.scss
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
============================ | ||
Web Widget Progressbar Color | ||
============================ | ||
=============================== | ||
Web Widget Progressbar Gradient | ||
=============================== | ||
|
||
.. | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
|
@@ -17,24 +17,24 @@ Web Widget Progressbar Color | |
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html | ||
:alt: License: AGPL-3 | ||
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fweb-lightgray.png?logo=github | ||
:target: https://github.com/OCA/web/tree/16.0/web_widget_progressbar_color | ||
:target: https://github.com/OCA/web/tree/16.0/web_widget_progressbar_gradient | ||
:alt: OCA/web | ||
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png | ||
:target: https://translation.odoo-community.org/projects/web-16-0/web-16-0-web_widget_progressbar_color | ||
:target: https://translation.odoo-community.org/projects/web-16-0/web-16-0-web_widget_progressbar_gradient | ||
:alt: Translate me on Weblate | ||
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png | ||
:target: https://runboat.odoo-community.org/builds?repo=OCA/web&target_branch=16.0 | ||
:alt: Try me on Runboat | ||
|
||
|badge1| |badge2| |badge3| |badge4| |badge5| | ||
|
||
This module allows to display progress bars with colorized bar. The | ||
color will be green for values between 0% and 40%, yellow for values | ||
between 40% and 70% and red between 70% and 100%. | ||
This module allows to display progress bars with colorized gradient bar. | ||
The color will increase following value from green passing per yellow | ||
and finishing to red. | ||
|
||
|Progressbar Color| | ||
|Progressbar Gradient| | ||
|
||
.. |Progressbar Color| image:: https://raw.githubusercontent.com/OCA/web/16.0/web_widget_progressbar_color/static/description/progressbar_color.png | ||
.. |Progressbar Gradient| image:: https://raw.githubusercontent.com/OCA/web/16.0/web_widget_progressbar_gradient/static/description/progressbar_gradient.png | ||
|
||
**Table of contents** | ||
|
||
|
@@ -59,7 +59,7 @@ Bug Tracker | |
Bugs are tracked on `GitHub Issues <https://github.com/OCA/web/issues>`_. | ||
In case of trouble, please check there if your issue has already been reported. | ||
If you spotted it first, help us to smash it by providing a detailed and welcomed | ||
`feedback <https://github.com/OCA/web/issues/new?body=module:%20web_widget_progressbar_color%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_. | ||
`feedback <https://github.com/OCA/web/issues/new?body=module:%20web_widget_progressbar_gradient%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_. | ||
|
||
Do not contact contributors directly about support or help with technical issues. | ||
|
||
|
@@ -75,6 +75,7 @@ Contributors | |
------------ | ||
|
||
- Denis Roussel [email protected] | ||
- Jacques-Etienne Baudoux [email protected] | ||
|
||
Maintainers | ||
----------- | ||
|
@@ -97,6 +98,6 @@ Current `maintainer <https://odoo-community.org/page/maintainer-role>`__: | |
|
||
|maintainer-rousseldenis| | ||
|
||
This module is part of the `OCA/web <https://github.com/OCA/web/tree/16.0/web_widget_progressbar_color>`_ project on GitHub. | ||
This module is part of the `OCA/web <https://github.com/OCA/web/tree/16.0/web_widget_progressbar_gradient>`_ project on GitHub. | ||
|
||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
..._progressbar_color/readme/CONTRIBUTORS.md → ...ogressbar_gradient/readme/CONTRIBUTORS.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
- Denis Roussel <[email protected]> | ||
- Jacques-Etienne Baudoux <[email protected]> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
This module allows to display progress bars with colorized gradient bar. | ||
The color will increase following value from green passing per yellow | ||
and finishing to red. | ||
|
||
![Progressbar Gradient](../static/description/progressbar_gradient.png) |
File renamed without changes.
File renamed without changes.
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+8.94 KB
web_widget_progressbar_gradient/static/description/progressbar_gradient.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
15 changes: 15 additions & 0 deletions
15
web_widget_progressbar_gradient/static/src/js/progressbar.esm.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/** @odoo-module | ||
* Copyright 2024 ACSONE SA/NV | ||
* License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). | ||
* **/ | ||
import {ProgressBarField} from "@web/views/fields/progress_bar/progress_bar_field"; | ||
import {registry} from "@web/core/registry"; | ||
|
||
export class ProgressBarFieldGradient extends ProgressBarField { | ||
setup() { | ||
super.setup(); | ||
} | ||
} | ||
ProgressBarFieldGradient.template = | ||
"web_widget_progressbar_color.ProgressBarFieldGradient"; | ||
registry.category("fields").add("progressbar_gradient", ProgressBarFieldGradient); |
19 changes: 19 additions & 0 deletions
19
web_widget_progressbar_gradient/static/src/scss/progressbar.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
div:has(div.o_progressbar_gradient) .o_progressbar .o_progress { | ||
position: relative; | ||
} | ||
|
||
.o_progressbar .o_progress .o_progressbar_gradient { | ||
height: 100%; | ||
/* this will do the magic for masking the gradient */ | ||
-webkit-mask: linear-gradient(#fff 0 0); | ||
mask: linear-gradient(#fff 0 0); | ||
} | ||
.o_progressbar .o_progress .o_progressbar_gradient::before { | ||
content: ""; | ||
position: absolute; | ||
top: 0; | ||
left: 0; | ||
right: 0; | ||
bottom: 0; | ||
background-image: linear-gradient(to right, #198754, #ffc107, #dc3545); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters