[IMP] web: CopyClipboardCharLong widget for long strings
- The copy CopyClipboardChar widget is not nicely rendered for very long strings (e.g. URL). - This commit modify the behavior of the CopyClipboardChar widget to display it nicely win such cases. TaskID: 2059972
This commit is contained in:
@@ -1597,13 +1597,6 @@ var CopyClipboard = {
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* @override
|
||||
*/
|
||||
_render: function () {
|
||||
this._super.apply(this, arguments);
|
||||
this.$el.addClass('o_field_copy');
|
||||
},
|
||||
/**
|
||||
* @override
|
||||
*/
|
||||
@@ -1619,11 +1612,13 @@ var CopyClipboard = {
|
||||
var TextCopyClipboard = FieldText.extend(CopyClipboard, {
|
||||
description: _lt("Copy to Clipboard"),
|
||||
clipboardTemplate: 'CopyClipboardText',
|
||||
className: "o_field_copy",
|
||||
});
|
||||
|
||||
var CharCopyClipboard = FieldChar.extend(CopyClipboard, {
|
||||
description: _lt("Copy to Clipboard"),
|
||||
clipboardTemplate: 'CopyClipboardChar',
|
||||
className: 'o_field_copy o_text_overflow',
|
||||
});
|
||||
|
||||
var AbstractFieldBinary = AbstractField.extend({
|
||||
|
||||
@@ -453,6 +453,7 @@
|
||||
font-weight: $badge-font-weight;
|
||||
text-align: center;
|
||||
padding-right: 100px;
|
||||
word-break: break-word;
|
||||
.o_clipboard_button {
|
||||
@include o-position-absolute($top: 0, $right: 0);
|
||||
&.o_btn_text_copy {
|
||||
|
||||
Reference in New Issue
Block a user