Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 22 additions & 1 deletion base_fontawesome/README.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
.. image:: https://odoo-community.org/readme-banner-image
:target: https://odoo-community.org/get-involved?utm_source=readme
:alt: Odoo Community Association

================
Base Fontawesome
================
Expand All @@ -13,7 +17,7 @@ Base Fontawesome
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/licence-LGPL--3-blue.png
.. |badge2| image:: https://img.shields.io/badge/license-LGPL--3-blue.png
:target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html
:alt: License: LGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fserver--tools-lightgray.png?logo=github
Expand Down Expand Up @@ -55,6 +59,22 @@ For example, brand_icon is necessary if we are using an icon of a brand::

<button brand_icon="fas fa-handshake-slash" string=" fas fa-handshake-slash"/>

Icon picker widget
~~~~~~~~~~~~~~~~~~~

This module also provides a reusable ``fontawesome_picker`` field widget. Apply it
to any ``Char`` field that stores a FontAwesome CSS class to get a searchable grid
of the icons currently loaded, with a live preview, instead of typing the class by
hand::

<field name="icon" widget="fontawesome_picker"/>

Selecting an icon writes its full class (for example ``fa fa-shopping-cart``) into
the field. The catalog is read at runtime from the loaded ``v4-shims`` stylesheet,
i.e. the icons that render with the standard ``fa fa-x`` class regardless of their
style (solid, regular or brand) and of the assets bundle they are shown in. The
widget is meant for form views.

Bug Tracker
===========

Expand All @@ -80,6 +100,7 @@ Contributors
* Simone Orsi simone.orsi@camptocamp.com
* Enric Tobella <etobella@creublanca.es>
* Tony Galmiche <tony.galmiche@infosaone.com>
* Mariano Martinez <mariano.martinez@factorlibre.com>

Maintainers
~~~~~~~~~~~
Expand Down
6 changes: 6 additions & 0 deletions base_fontawesome/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,11 @@
"base_fontawesome/static/lib/fontawesome-6.5.1/css/all.css",
"base_fontawesome/static/lib/fontawesome-6.5.1/css/v4-shims.css",
],
"web.assets_backend": [
"base_fontawesome/static/src/fields/**/*",
],
"web.qunit_suite_tests": [
"base_fontawesome/static/tests/**/*",
],
},
}
38 changes: 38 additions & 0 deletions base_fontawesome/i18n/base_fontawesome.pot
Original file line number Diff line number Diff line change
@@ -1,13 +1,51 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * base_fontawesome
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-06-24 11:44+0000\n"
"PO-Revision-Date: 2026-06-24 11:44+0000\n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "Clear"
msgstr ""

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "No FontAwesome icons available."
msgstr ""

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "Refine your search to narrow the list."
msgstr ""

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "Search icon..."
msgstr ""

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "Select an icon"
msgstr ""
52 changes: 52 additions & 0 deletions base_fontawesome/i18n/es_ES.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * base_fontawesome
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-06-24 11:44+0000\n"
"PO-Revision-Date: 2026-06-24 11:44+0000\n"
"Last-Translator: \n"
"Language-Team: \n"
"Language: es_ES\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "Clear"
msgstr "Limpiar"

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "No FontAwesome icons available."
msgstr "No hay iconos de FontAwesome disponibles."

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "Refine your search to narrow the list."
msgstr "Refina la búsqueda para acotar la lista."

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "Search icon..."
msgstr "Buscar icono..."

#. module: base_fontawesome
#. odoo-javascript
#: code:addons/base_fontawesome/static/src/fields/fontawesome_picker/fontawesome_picker.esm.js:0
#, python-format
msgid "Select an icon"
msgstr "Seleccionar un icono"
1 change: 1 addition & 0 deletions base_fontawesome/readme/CONTRIBUTORS.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
* Simone Orsi simone.orsi@camptocamp.com
* Enric Tobella <etobella@creublanca.es>
* Tony Galmiche <tony.galmiche@infosaone.com>
* Mariano Martinez <mariano.martinez@factorlibre.com>
16 changes: 16 additions & 0 deletions base_fontawesome/readme/USAGE.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,19 @@ For example, brand_icon is necessary if we are using an icon of a brand::
<button brand_icon="fas fa-hand-sparkles" string=" fas fa-hand-sparkles"/>

<button brand_icon="fas fa-handshake-slash" string=" fas fa-handshake-slash"/>

Icon picker widget
~~~~~~~~~~~~~~~~~~~

This module also provides a reusable ``fontawesome_picker`` field widget. Apply it
to any ``Char`` field that stores a FontAwesome CSS class to get a searchable grid
of the icons currently loaded, with a live preview, instead of typing the class by
hand::

<field name="icon" widget="fontawesome_picker"/>

Selecting an icon writes its full class (for example ``fa fa-shopping-cart``) into
the field. The catalog is read at runtime from the loaded ``v4-shims`` stylesheet,
i.e. the icons that render with the standard ``fa fa-x`` class regardless of their
style (solid, regular or brand) and of the assets bundle they are shown in. The
widget is meant for form views.
68 changes: 48 additions & 20 deletions base_fontawesome/static/description/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,16 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="generator" content="Docutils: https://docutils.sourceforge.io/" />
<title>Base Fontawesome</title>
<title>README.rst</title>
<style type="text/css">

/*
:Author: David Goodger (goodger@python.org)
:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $
:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $
:Copyright: This stylesheet has been placed in the public domain.

Default cascading style sheet for the HTML output of Docutils.
Despite the name, some widely supported CSS2 features are used.

See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to
customize this style sheet.
Expand Down Expand Up @@ -274,7 +275,7 @@
margin-left: 2em ;
margin-right: 2em }

pre.code .ln { color: grey; } /* line numbers */
pre.code .ln { color: gray; } /* line numbers */
pre.code, code { background-color: #eeeeee }
pre.code .comment, code .comment { color: #5C6576 }
pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold }
Expand All @@ -300,7 +301,7 @@
span.pre {
white-space: pre }

span.problematic {
span.problematic, pre.problematic {
color: red }

span.section-subtitle {
Expand Down Expand Up @@ -359,33 +360,41 @@
</style>
</head>
<body>
<div class="document" id="base-fontawesome">
<h1 class="title">Base Fontawesome</h1>
<div class="document">


<a class="reference external image-reference" href="https://odoo-community.org/get-involved?utm_source=readme">
<img alt="Odoo Community Association" src="https://odoo-community.org/readme-banner-image" />
</a>
<div class="section" id="base-fontawesome">
<h1>Base Fontawesome</h1>
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:cbde256adbb89a55ad8f7196b809b220a4df086ae08a211e005b9c5572004983
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/lgpl-3.0-standalone.html"><img alt="License: LGPL-3" src="https://img.shields.io/badge/licence-LGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/server-tools/tree/16.0/base_fontawesome"><img alt="OCA/server-tools" src="https://img.shields.io/badge/github-OCA%2Fserver--tools-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/server-tools-16-0/server-tools-16-0-base_fontawesome"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/server-tools&amp;target_branch=16.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/lgpl-3.0-standalone.html"><img alt="License: LGPL-3" src="https://img.shields.io/badge/license-LGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/server-tools/tree/16.0/base_fontawesome"><img alt="OCA/server-tools" src="https://img.shields.io/badge/github-OCA%2Fserver--tools-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/server-tools-16-0/server-tools-16-0-base_fontawesome"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/server-tools&amp;target_branch=16.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
<p>Provide up to date <a class="reference external" href="http://fontawesome.io/">Fontawesome</a> resources.</p>
<p>Current version: 6.5.1 (the version of this module matches it).</p>
<p><strong>Table of contents</strong></p>
<div class="contents local topic" id="contents">
<ul class="simple">
<li><a class="reference internal" href="#usage" id="toc-entry-1">Usage</a></li>
<li><a class="reference internal" href="#bug-tracker" id="toc-entry-2">Bug Tracker</a></li>
<li><a class="reference internal" href="#credits" id="toc-entry-3">Credits</a><ul>
<li><a class="reference internal" href="#authors" id="toc-entry-4">Authors</a></li>
<li><a class="reference internal" href="#contributors" id="toc-entry-5">Contributors</a></li>
<li><a class="reference internal" href="#maintainers" id="toc-entry-6">Maintainers</a></li>
<li><a class="reference internal" href="#usage" id="toc-entry-1">Usage</a><ul>
<li><a class="reference internal" href="#icon-picker-widget" id="toc-entry-2">Icon picker widget</a></li>
</ul>
</li>
<li><a class="reference internal" href="#bug-tracker" id="toc-entry-3">Bug Tracker</a></li>
<li><a class="reference internal" href="#credits" id="toc-entry-4">Credits</a><ul>
<li><a class="reference internal" href="#authors" id="toc-entry-5">Authors</a></li>
<li><a class="reference internal" href="#contributors" id="toc-entry-6">Contributors</a></li>
<li><a class="reference internal" href="#maintainers" id="toc-entry-7">Maintainers</a></li>
</ul>
</li>
</ul>
</div>
<div class="section" id="usage">
<h1><a class="toc-backref" href="#toc-entry-1">Usage</a></h1>
<h2><a class="toc-backref" href="#toc-entry-1">Usage</a></h2>
<p>Now, all free icons from <a class="reference external" href="https://fontawesome.com/icons?d=gallery&amp;m=free">Font Awesome</a>
can be used on odoo. It also adds three options in order to add the icons:
* solid_icon
Expand All @@ -400,36 +409,54 @@ <h1><a class="toc-backref" href="#toc-entry-1">Usage</a></h1>

&lt;button brand_icon=&quot;fas fa-handshake-slash&quot; string=&quot; fas fa-handshake-slash&quot;/&gt;
</pre>
<div class="section" id="icon-picker-widget">
<h3><a class="toc-backref" href="#toc-entry-2">Icon picker widget</a></h3>
<p>This module also provides a reusable <tt class="docutils literal">fontawesome_picker</tt> field widget. Apply it
to any <tt class="docutils literal">Char</tt> field that stores a FontAwesome CSS class to get a searchable grid
of the icons currently loaded, with a live preview, instead of typing the class by
hand:</p>
<pre class="literal-block">
&lt;field name=&quot;icon&quot; widget=&quot;fontawesome_picker&quot;/&gt;
</pre>
<p>Selecting an icon writes its full class (for example <tt class="docutils literal">fa <span class="pre">fa-shopping-cart</span></tt>) into
the field. The catalog is read at runtime from the loaded <tt class="docutils literal"><span class="pre">v4-shims</span></tt> stylesheet,
i.e. the icons that render with the standard <tt class="docutils literal">fa <span class="pre">fa-x</span></tt> class regardless of their
style (solid, regular or brand) and of the assets bundle they are shown in. The
widget is meant for form views.</p>
</div>
</div>
<div class="section" id="bug-tracker">
<h1><a class="toc-backref" href="#toc-entry-2">Bug Tracker</a></h1>
<h2><a class="toc-backref" href="#toc-entry-3">Bug Tracker</a></h2>
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/server-tools/issues">GitHub Issues</a>.
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
<a class="reference external" href="https://github.com/OCA/server-tools/issues/new?body=module:%20base_fontawesome%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<p>Do not contact contributors directly about support or help with technical issues.</p>
</div>
<div class="section" id="credits">
<h1><a class="toc-backref" href="#toc-entry-3">Credits</a></h1>
<h2><a class="toc-backref" href="#toc-entry-4">Credits</a></h2>
<div class="section" id="authors">
<h2><a class="toc-backref" href="#toc-entry-4">Authors</a></h2>
<h3><a class="toc-backref" href="#toc-entry-5">Authors</a></h3>
<ul class="simple">
<li>Camptocamp</li>
<li>Creu Blanca</li>
</ul>
</div>
<div class="section" id="contributors">
<h2><a class="toc-backref" href="#toc-entry-5">Contributors</a></h2>
<h3><a class="toc-backref" href="#toc-entry-6">Contributors</a></h3>
<ul class="simple">
<li>Simone Orsi <a class="reference external" href="mailto:simone.orsi&#64;camptocamp.com">simone.orsi&#64;camptocamp.com</a></li>
<li>Enric Tobella &lt;<a class="reference external" href="mailto:etobella&#64;creublanca.es">etobella&#64;creublanca.es</a>&gt;</li>
<li>Tony Galmiche &lt;<a class="reference external" href="mailto:tony.galmiche&#64;infosaone.com">tony.galmiche&#64;infosaone.com</a>&gt;</li>
<li>Mariano Martinez &lt;<a class="reference external" href="mailto:mariano.martinez&#64;factorlibre.com">mariano.martinez&#64;factorlibre.com</a>&gt;</li>
</ul>
</div>
<div class="section" id="maintainers">
<h2><a class="toc-backref" href="#toc-entry-6">Maintainers</a></h2>
<h3><a class="toc-backref" href="#toc-entry-7">Maintainers</a></h3>
<p>This module is maintained by the OCA.</p>
<a class="reference external image-reference" href="https://odoo-community.org"><img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" /></a>
<a class="reference external image-reference" href="https://odoo-community.org">
<img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" />
</a>
<p>OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.</p>
Expand All @@ -438,5 +465,6 @@ <h2><a class="toc-backref" href="#toc-entry-6">Maintainers</a></h2>
</div>
</div>
</div>
</div>
</body>
</html>
Loading
Loading