Rename theme to concord
and add config option for setting the theme
This commit is contained in:
parent
dde2efb653
commit
352c0797ad
@ -6,6 +6,7 @@
|
|||||||
- Default paths in converse-notifications.js are now relative
|
- Default paths in converse-notifications.js are now relative
|
||||||
- Add a button to regenerate OMEMO keys
|
- Add a button to regenerate OMEMO keys
|
||||||
- Add client info modal which shows Converse's version number
|
- Add client info modal which shows Converse's version number
|
||||||
|
- New config setting [theme](https://conversejs.org/docs/html/configuration.html#theme)
|
||||||
- #141 XEP-0184: Message Delivery Receipts
|
- #141 XEP-0184: Message Delivery Receipts
|
||||||
- #1033 Setting show_send_button to true didn't work
|
- #1033 Setting show_send_button to true didn't work
|
||||||
- #1188 Feature request: drag and drop file to HTTP Upload
|
- #1188 Feature request: drag and drop file to HTTP Upload
|
||||||
|
@ -9413,7 +9413,7 @@ readers do not read off random characters that represent icons */
|
|||||||
--list-minus-circle-color: #f0a794;
|
--list-minus-circle-color: #f0a794;
|
||||||
--list-dot-circle-color: #f6dec1; }
|
--list-dot-circle-color: #f6dec1; }
|
||||||
|
|
||||||
#conversejs.theme-dark {
|
#conversejs.theme-concord {
|
||||||
--avatar-border-radius: 100%;
|
--avatar-border-radius: 100%;
|
||||||
--avatar-border: 0px;
|
--avatar-border: 0px;
|
||||||
--avatar-background-color: none;
|
--avatar-background-color: none;
|
||||||
|
15
dist/converse.js
vendored
15
dist/converse.js
vendored
@ -58506,7 +58506,9 @@ __webpack_require__.r(__webpack_exports__);
|
|||||||
|
|
||||||
const _converse$env = _converse_headless_converse_core__WEBPACK_IMPORTED_MODULE_3__["default"].env,
|
const _converse$env = _converse_headless_converse_core__WEBPACK_IMPORTED_MODULE_3__["default"].env,
|
||||||
Backbone = _converse$env.Backbone,
|
Backbone = _converse$env.Backbone,
|
||||||
_ = _converse$env._;
|
_ = _converse$env._,
|
||||||
|
utils = _converse$env.utils;
|
||||||
|
const u = utils;
|
||||||
const AvatarMixin = {
|
const AvatarMixin = {
|
||||||
renderAvatar(el) {
|
renderAvatar(el) {
|
||||||
el = el || this.el;
|
el = el || this.el;
|
||||||
@ -58566,7 +58568,15 @@ _converse_headless_converse_core__WEBPACK_IMPORTED_MODULE_3__["default"].plugins
|
|||||||
const _converse = this._converse,
|
const _converse = this._converse,
|
||||||
__ = _converse.__;
|
__ = _converse.__;
|
||||||
|
|
||||||
_converse.api.promises.add(['chatBoxViewsInitialized']);
|
_converse.api.promises.add(['chatBoxViewsInitialized']); // Configuration values for this plugin
|
||||||
|
// ====================================
|
||||||
|
// Refer to docs/source/configuration.rst for explanations of these
|
||||||
|
// configuration settings.
|
||||||
|
|
||||||
|
|
||||||
|
_converse.api.settings.update({
|
||||||
|
'theme': 'default'
|
||||||
|
});
|
||||||
|
|
||||||
_converse.ViewWithAvatar = Backbone.NativeView.extend(AvatarMixin);
|
_converse.ViewWithAvatar = Backbone.NativeView.extend(AvatarMixin);
|
||||||
_converse.VDOMViewWithAvatar = Backbone.VDOMView.extend(AvatarMixin);
|
_converse.VDOMViewWithAvatar = Backbone.VDOMView.extend(AvatarMixin);
|
||||||
@ -58581,6 +58591,7 @@ _converse_headless_converse_core__WEBPACK_IMPORTED_MODULE_3__["default"].plugins
|
|||||||
if (_.isNull(el)) {
|
if (_.isNull(el)) {
|
||||||
el = document.createElement('div');
|
el = document.createElement('div');
|
||||||
el.setAttribute('id', 'conversejs');
|
el.setAttribute('id', 'conversejs');
|
||||||
|
u.addClass(`theme-${_converse.theme}`, el);
|
||||||
|
|
||||||
const body = _converse.root.querySelector('body');
|
const body = _converse.root.querySelector('body');
|
||||||
|
|
||||||
|
@ -1379,6 +1379,16 @@ If set to ``false``, this feature is disabled.
|
|||||||
|
|
||||||
If set to ``a resource name``, Converse will synchronize only with a client that has that particular resource assigned to it.
|
If set to ``a resource name``, Converse will synchronize only with a client that has that particular resource assigned to it.
|
||||||
|
|
||||||
|
theme
|
||||||
|
-----
|
||||||
|
|
||||||
|
* Default: ``default``
|
||||||
|
|
||||||
|
Valid options: ``default``, ``concord``
|
||||||
|
|
||||||
|
Let's you set a color theme for Converse.
|
||||||
|
|
||||||
|
|
||||||
trusted
|
trusted
|
||||||
-------
|
-------
|
||||||
|
|
||||||
|
@ -173,7 +173,7 @@ $font-path: "webfonts/icomoon/fonts/" !default;
|
|||||||
--list-dot-circle-color: #f6dec1; // lighten($orange, 25%)
|
--list-dot-circle-color: #f6dec1; // lighten($orange, 25%)
|
||||||
}
|
}
|
||||||
|
|
||||||
#conversejs.theme-dark {
|
#conversejs.theme-concord {
|
||||||
--avatar-border-radius: 100%;
|
--avatar-border-radius: 100%;
|
||||||
--avatar-border: 0px;
|
--avatar-border: 0px;
|
||||||
--avatar-background-color: none;
|
--avatar-background-color: none;
|
||||||
|
@ -10,7 +10,8 @@ import "backbone.overview";
|
|||||||
import converse from "@converse/headless/converse-core";
|
import converse from "@converse/headless/converse-core";
|
||||||
import tpl_chatboxes from "templates/chatboxes.html";
|
import tpl_chatboxes from "templates/chatboxes.html";
|
||||||
|
|
||||||
const { Backbone, _ } = converse.env;
|
const { Backbone, _, utils } = converse.env;
|
||||||
|
const u = utils;
|
||||||
|
|
||||||
const AvatarMixin = {
|
const AvatarMixin = {
|
||||||
|
|
||||||
@ -74,6 +75,14 @@ converse.plugins.add('converse-chatboxviews', {
|
|||||||
'chatBoxViewsInitialized'
|
'chatBoxViewsInitialized'
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
// Configuration values for this plugin
|
||||||
|
// ====================================
|
||||||
|
// Refer to docs/source/configuration.rst for explanations of these
|
||||||
|
// configuration settings.
|
||||||
|
_converse.api.settings.update({
|
||||||
|
'theme': 'default',
|
||||||
|
});
|
||||||
|
|
||||||
_converse.ViewWithAvatar = Backbone.NativeView.extend(AvatarMixin);
|
_converse.ViewWithAvatar = Backbone.NativeView.extend(AvatarMixin);
|
||||||
_converse.VDOMViewWithAvatar = Backbone.VDOMView.extend(AvatarMixin);
|
_converse.VDOMViewWithAvatar = Backbone.VDOMView.extend(AvatarMixin);
|
||||||
|
|
||||||
@ -89,6 +98,7 @@ converse.plugins.add('converse-chatboxviews', {
|
|||||||
if (_.isNull(el)) {
|
if (_.isNull(el)) {
|
||||||
el = document.createElement('div');
|
el = document.createElement('div');
|
||||||
el.setAttribute('id', 'conversejs');
|
el.setAttribute('id', 'conversejs');
|
||||||
|
u.addClass(`theme-${_converse.theme}`, el);
|
||||||
const body = _converse.root.querySelector('body');
|
const body = _converse.root.querySelector('body');
|
||||||
if (body) {
|
if (body) {
|
||||||
body.appendChild(el);
|
body.appendChild(el);
|
||||||
|
Loading…
Reference in New Issue
Block a user