Bugzilla – Attachment 167261 Details for
Bug 35134
cn_browser.pl pop-up size should be configurable
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 35134: Make cn_browser popup responsive to screen size
Bug-35134-Make-cnbrowser-popup-responsive-to-scree.patch (text/plain), 1.67 KB, created by
David Nind
on 2024-05-30 05:15:10 UTC
(
hide
)
Description:
Bug 35134: Make cn_browser popup responsive to screen size
Filename:
MIME Type:
Creator:
David Nind
Created:
2024-05-30 05:15:10 UTC
Size:
1.67 KB
patch
obsolete
>From 4062b321ef58f6731ee7a9da2351e09e409b0b5b Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Tue, 21 Nov 2023 15:26:13 +0000 >Subject: [PATCH] Bug 35134: Make cn_browser popup responsive to screen size > >To test: >1. Use the cn_browser.pl plugin for the 952$o ( call number ) >2. Add or edit an item and select the `...` to the right of the call > number field. >3. The pop-up is hardcoded as 500px x 400px pop-up. >4. APPLY PATCH >5. Clear browser cache and try again. The window width should now be > half of the current screen size. The window height should be 100% of > the screen height. > >Signed-off-by: Owen Leonard <oleonard@myacpl.org> >Signed-off-by: David Nind <david@davidnind.com> >--- > cataloguing/value_builder/cn_browser.pl | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > >diff --git a/cataloguing/value_builder/cn_browser.pl b/cataloguing/value_builder/cn_browser.pl >index 55128fc7bc..881103c8f8 100755 >--- a/cataloguing/value_builder/cn_browser.pl >+++ b/cataloguing/value_builder/cn_browser.pl >@@ -35,8 +35,10 @@ my $builder = sub { > > function Click$function_name(ev) { > ev.preventDefault(); >+ let window_width = screen.width / 2; >+ let window_height = screen.height; > q = document.getElementById(ev.data.id); >- window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=cn_browser.pl&popup&q=\"+encodeURIComponent(q.value),\"cnbrowser\",\"width=500,height=400,toolbar=false,scrollbars=yes\"); >+ window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=cn_browser.pl&popup&q=\"+encodeURIComponent(q.value),\"cnbrowser\",\"width=\"+window_width+\"\,height=\"+window_height+\"\,toolbar=false,scrollbars=yes\"); > } > > </script> >-- >2.39.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 35134
:
159169
|
159171
|
165381
| 167261 |
167262