-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fbf167e
commit 0c20b2f
Showing
19 changed files
with
533 additions
and
76 deletions.
There are no files selected for viewing
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
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
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,109 @@ | ||
/*! | ||
* --------------------------------------------------------------------- | ||
* | ||
* GLPI - Gestionnaire Libre de Parc Informatique | ||
* | ||
* http://glpi-project.org | ||
* | ||
* @copyright 2015-2024 Teclib' and contributors. | ||
* @copyright 2003-2014 by the INDEPNET Development Team. | ||
* @licence https://www.gnu.org/licenses/gpl-3.0.html | ||
* | ||
* --------------------------------------------------------------------- | ||
* | ||
* LICENSE | ||
* | ||
* This file is part of GLPI. | ||
* | ||
* This program is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License | ||
* along with this program. If not, see <https://www.gnu.org/licenses/>. | ||
* | ||
* --------------------------------------------------------------------- | ||
*/ | ||
|
||
/** | ||
* Styles for inputs that are disguised as "content editable" DOM elements | ||
* This inputs may be more convenient than real "content-editable" elements for | ||
* some use cases (richtext editor, ...) | ||
*/ | ||
|
||
// Padding for content-editable inputs | ||
// Must not be too high as content-editable is usually done without padding | ||
$inline-input-padding: 2px 4px; | ||
|
||
.content-editable-h2 { | ||
// Copy h2 styles | ||
font-size: 1.2rem !important; | ||
line-height: 1.5rem; | ||
font-weight: var(--tblr-font-weight-medium); | ||
border: 0; | ||
padding: $inline-input-padding; | ||
margin-bottom: 1rem; | ||
background-color: transparent; | ||
|
||
&:hover { | ||
box-shadow: 0 0 0 0.25rem rgba(var(--tblr-primary-rgb), 0.20); | ||
} | ||
} | ||
|
||
|
||
.content-editable-tinymce { | ||
// Remove default border and padding, add similar hover style used on our inputs | ||
.tox-tinymce { | ||
border-color: transparent !important; | ||
padding: $inline-input-padding; | ||
|
||
&:hover { | ||
box-shadow: 0 0 0 0.25rem rgba(var(--tblr-primary-rgb), 0.20); | ||
} | ||
} | ||
|
||
// Status bar is empty here, do not display to gain some vertical space | ||
.tox-statusbar { | ||
display: none !important; | ||
} | ||
|
||
// Small left padding to match our content-editable inputs padding | ||
.tox-toolbar__primary { | ||
.tox-toolbar__group:first-child { | ||
padding-left: 2px !important; | ||
} | ||
} | ||
|
||
// Hide richtext actions toolbor | ||
.tox-editor-header { | ||
// Can't use "display: none" as tinymce doens't like it and it break | ||
// the rendering of the header (probably caused by some calculations done | ||
// on width) | ||
opacity: 0; | ||
height: 0; | ||
} | ||
} | ||
|
||
// Simulate focus like a bootstrap input, needed for tinymce with some javascript | ||
// help to trigger and remove the class as needed | ||
.simulate-focus { | ||
box-shadow: 0 0 0 0.25rem rgba(var(--tblr-primary-rgb), 0.20); | ||
|
||
// Show richtext toolbar only when focused | ||
.tox-editor-header { | ||
opacity: unset; | ||
height: unset; | ||
} | ||
} | ||
|
||
// Class inside tinymce's iframe, remove internal padding | ||
.content-editable-tinymce-editor { | ||
margin: 0 !important; | ||
padding: 0 !important; | ||
} |
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,63 @@ | ||
/*! | ||
* --------------------------------------------------------------------- | ||
* | ||
* GLPI - Gestionnaire Libre de Parc Informatique | ||
* | ||
* http://glpi-project.org | ||
* | ||
* @copyright 2015-2024 Teclib' and contributors. | ||
* @copyright 2003-2014 by the INDEPNET Development Team. | ||
* @licence https://www.gnu.org/licenses/gpl-3.0.html | ||
* | ||
* --------------------------------------------------------------------- | ||
* | ||
* LICENSE | ||
* | ||
* This file is part of GLPI. | ||
* | ||
* This program is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License | ||
* along with this program. If not, see <https://www.gnu.org/licenses/>. | ||
* | ||
* --------------------------------------------------------------------- | ||
*/ | ||
|
||
.form-editor { | ||
// Use all available parent space | ||
flex-grow: 1; | ||
|
||
// Subtle gradient to avoid white on white cards while still keeping a white/white connection to the active tab (experimental) | ||
// TODO: keep / remove / tweak when the UX is more complete (questions, sections, ...) | ||
background: linear-gradient( | ||
169deg, | ||
rgb(255,255,255) 0%, | ||
rgb(254,254,254) 14%, | ||
rgb(253,253,253) 22%, | ||
rgb(252,252,252) 33%, | ||
rgb(251,251,252) 41%, | ||
rgb(248,250,252) 48% | ||
); | ||
|
||
.designer { | ||
.form-details { | ||
.card-title { | ||
// Emphasis form title with an above average font size | ||
font-size: 1.2rem !important; | ||
} | ||
} | ||
} | ||
} | ||
|
||
.editor-footer { | ||
border-top: 1px solid $border-color; | ||
background: var(--glpi-form-toolbar-bg); | ||
} |
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
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
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
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
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
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
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
Oops, something went wrong.