@textback/notification-widget 2.0.9 → 2.0.11-dev
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@textback/notification-widget",
|
3
|
-
"version": "2.0.
|
3
|
+
"version": "2.0.11-dev",
|
4
4
|
"description": "TODO: Give a short introduction of your project. Let this section explain the objectives or the motivation behind this project.",
|
5
5
|
"main": "build/index.js",
|
6
6
|
"scripts": {
|
package/readme.md
CHANGED
@@ -534,7 +534,7 @@ TextBack.SDK.initWidget(config).then(
|
|
534
534
|
|
535
535
|
# Разработка
|
536
536
|
|
537
|
-
В терминале перейдите в директорию исходного кода виджета и выполните
|
537
|
+
В терминале перейдите в директорию исходного кода виджета и выполните команды, использую версию ноды v.12:
|
538
538
|
|
539
539
|
```
|
540
540
|
npm run dev
|
@@ -68,10 +68,12 @@ export default class Widget extends Component {
|
|
68
68
|
this.previewMode = this.previewMode || this.element.hasAttribute('preview-mode');
|
69
69
|
|
70
70
|
const predefinedConfig = this.widgetConfig;
|
71
|
+
console.log(predefinedConfig);
|
71
72
|
|
72
73
|
//override widgetId property with data from widgetConfig
|
73
74
|
if (!!predefinedConfig) {
|
74
75
|
this.widgetId = predefinedConfig.id;
|
76
|
+
this.hideTbBrandLogo = predefinedConfig.hideTbBrandLogo;
|
75
77
|
}
|
76
78
|
|
77
79
|
let widgetInitPromise = SDK.getWidget(this.widgetId);
|
@@ -93,6 +95,7 @@ export default class Widget extends Component {
|
|
93
95
|
|
94
96
|
this.widgetUserId = widget.widgetUserId;
|
95
97
|
this.config = widget.getConfig();
|
98
|
+
this.config.hideTbBrandLogo = this.hideTbBrandLogo;
|
96
99
|
this.config.type = this.config.type || constants.DEFAULT_WIDGET_TYPE;
|
97
100
|
this.config.markUp = this.config.markUp || {};
|
98
101
|
this.config.markUp.buttons = assign({}, DEFAULT_BUTTONS_MARKUP, this.config.markUp.buttons);
|
@@ -441,7 +444,7 @@ export default class Widget extends Component {
|
|
441
444
|
<tb-notification-widget-overlay class="hidden">
|
442
445
|
<tb-notification-widget-popup class="${popupStyleClass}">
|
443
446
|
<span id="tb-notification-widget-close" class="tb-notification-widget-close-icon">×</span>
|
444
|
-
${this.getTbBrandBadge(this.config)}
|
447
|
+
${this.config.hideTbBrandLogo ? '' : this.getTbBrandBadge(this.config)}
|
445
448
|
<tb-nw-wahunter class="tb-nw-wahunter tb-nw-wahunter_mode_popup ${wahunterImageAlignClassName}"></tb-nw-wahunter>
|
446
449
|
</tb-notification-widget-popup>
|
447
450
|
</tb-notification-widget-overlay>
|
@@ -481,7 +484,7 @@ export default class Widget extends Component {
|
|
481
484
|
<tb-notification-widget-overlay class="hidden">
|
482
485
|
<tb-notification-widget-popup class="${popupStyleClass}">
|
483
486
|
<span id="tb-notification-widget-close" class="tb-notification-widget-close-icon">×</span>
|
484
|
-
${this.getTbBrandBadge(this.config)}
|
487
|
+
${this.config.hideTbBrandLogo ? '' : this.getTbBrandBadge(this.config)}
|
485
488
|
<tb-notification-widget-popup-body class="${popupBodyStyleClass}">
|
486
489
|
${(markUp.image && markUp.image.show) ? this.image : this.icon}
|
487
490
|
<tb-notification-widget-popup-main>
|
@@ -555,7 +558,7 @@ export default class Widget extends Component {
|
|
555
558
|
${iconClose}
|
556
559
|
</div>
|
557
560
|
<tb-nw-wahunter class="tb-nw-wahunter tb-nw-wahunter_mode_corner-popup"></tb-nw-wahunter>
|
558
|
-
${this.getTbBrandBadge(this.config)}
|
561
|
+
${this.config.hideTbBrandLogo ? '' : this.getTbBrandBadge(this.config)}
|
559
562
|
</tb-widget-corner-popup-window>
|
560
563
|
<tb-widget-corner-popup-button style="background: ${markUp.wahunterButton.color}">
|
561
564
|
${iconChatWindow}
|
@@ -215,10 +215,13 @@ tb-notification-widget
|
|
215
215
|
position: relative;
|
216
216
|
height: 14px;
|
217
217
|
width: 14px;
|
218
|
+
min-width: 14px;
|
219
|
+
min-height: 14px;
|
218
220
|
border: 1px solid rgb(207, 207, 207);
|
219
221
|
border-radius: 4px;
|
220
222
|
outline: none;
|
221
223
|
cursor: pointer;
|
224
|
+
margin-top: 2px;
|
222
225
|
|
223
226
|
&:checked {
|
224
227
|
background: $color-green;
|