From 4e5c19e9323c25e4b0d93a648221eecbe7db7ce5 Mon Sep 17 00:00:00 2001 From: snipe Date: Tue, 18 Nov 2025 13:11:40 +0000 Subject: [PATCH] Fixed #18202 - copy to clipboard adding spaces in FF --- resources/views/blade/copy-to-clipboard.blade.php | 5 ++--- resources/views/hardware/view.blade.php | 5 +---- resources/views/partials/bootstrap-table.blade.php | 2 +- 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/resources/views/blade/copy-to-clipboard.blade.php b/resources/views/blade/copy-to-clipboard.blade.php index 285940fef0..5932f2f66f 100644 --- a/resources/views/blade/copy-to-clipboard.blade.php +++ b/resources/views/blade/copy-to-clipboard.blade.php @@ -7,9 +7,8 @@ {{ trans('general.copy_to_clipboard') }} +{{--There must not be any spaces or line breaks between the js-copy span and the slot, or it will add a space before the copied value in Firefox :( --}} @if (!$slot->isEmpty()) - - {{ $slot }} - +{{ $slot }} @endif diff --git a/resources/views/hardware/view.blade.php b/resources/views/hardware/view.blade.php index a966674af8..e65d95f606 100755 --- a/resources/views/hardware/view.blade.php +++ b/resources/views/hardware/view.blade.php @@ -437,9 +437,7 @@ {{ trans('admin/hardware/form.tag') }}
- - {{ $asset->asset_tag }} - + {{ $asset->asset_tag }}
@endif @@ -724,7 +722,6 @@ {{-- Hidden span used as copy target --}} {{-- It's tempting to break out the HTML into separate lines for this, but it results in extra spaces being added onto the end of the copied value --}} @if (($field->field_encrypted=='1') && (Gate::allows('assets.view.encrypted_custom_fields'))) - {{ ($field->isFieldDecryptable($asset->{$field->db_column_name()}) ? Helper::gracefulDecrypt($field, $asset->{$field->db_column_name()}) : $asset->{$field->db_column_name()}) }} @elseif (($field->field_encrypted=='1') && (Gate::denies('assets.view.encrypted_custom_fields'))) {{ strtoupper(trans('admin/custom_fields/general.encrypted')) }} diff --git a/resources/views/partials/bootstrap-table.blade.php b/resources/views/partials/bootstrap-table.blade.php index d5bee14484..e3ed850f3f 100644 --- a/resources/views/partials/bootstrap-table.blade.php +++ b/resources/views/partials/bootstrap-table.blade.php @@ -999,7 +999,7 @@ } }; } - + function colorTagFormatter(value, row) { if (value) {