From c6e0eb2aa2aae044917130a8e29b639eb6266b72 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Grzegorz=20Zaja=CC=A8c?= Date: Wed, 19 Jul 2023 16:10:34 +0200 Subject: [PATCH 1/2] #1302 Safari icon improvement --- .../project.pbxproj | 8 ++++---- src/background/functions/setIcon.js | 12 +++++++----- src/images/icons/icon128safari.png | Bin 0 -> 2292 bytes src/images/icons/icon16safari.png | Bin 0 -> 362 bytes src/images/icons/icon32safari.png | Bin 0 -> 676 bytes src/images/icons/icon48safari.png | Bin 0 -> 901 bytes src/images/icons/icon96safari.png | Bin 0 -> 1853 bytes src/manifest/safari.json | 10 +++++----- 8 files changed, 16 insertions(+), 14 deletions(-) create mode 100644 src/images/icons/icon128safari.png create mode 100644 src/images/icons/icon16safari.png create mode 100644 src/images/icons/icon32safari.png create mode 100644 src/images/icons/icon48safari.png create mode 100644 src/images/icons/icon96safari.png diff --git a/2FAS - Two factor authentication/2FAS - Two Factor Authentication.xcodeproj/project.pbxproj b/2FAS - Two factor authentication/2FAS - Two Factor Authentication.xcodeproj/project.pbxproj index 6d27e6e..c5686f3 100644 --- a/2FAS - Two factor authentication/2FAS - Two Factor Authentication.xcodeproj/project.pbxproj +++ b/2FAS - Two factor authentication/2FAS - Two Factor Authentication.xcodeproj/project.pbxproj @@ -498,7 +498,7 @@ CODE_SIGN_IDENTITY = "Apple Development"; "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 28; + CURRENT_PROJECT_VERSION = 29; DEAD_CODE_STRIPPING = YES; DEVELOPMENT_TEAM = ZY8UR5ADFW; ENABLE_HARDENED_RUNTIME = YES; @@ -534,7 +534,7 @@ CODE_SIGN_IDENTITY = "Apple Development"; "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 28; + CURRENT_PROJECT_VERSION = 29; DEAD_CODE_STRIPPING = YES; DEVELOPMENT_TEAM = ZY8UR5ADFW; ENABLE_HARDENED_RUNTIME = YES; @@ -572,7 +572,7 @@ CODE_SIGN_ENTITLEMENTS = "macOS (App)/2FAS - Two factor authentication.entitlements"; CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 28; + CURRENT_PROJECT_VERSION = 29; DEAD_CODE_STRIPPING = YES; DEVELOPMENT_TEAM = ZY8UR5ADFW; ENABLE_HARDENED_RUNTIME = YES; @@ -613,7 +613,7 @@ CODE_SIGN_IDENTITY = "Apple Distribution"; "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 28; + CURRENT_PROJECT_VERSION = 29; DEAD_CODE_STRIPPING = YES; DEVELOPMENT_TEAM = ZY8UR5ADFW; ENABLE_HARDENED_RUNTIME = YES; diff --git a/src/background/functions/setIcon.js b/src/background/functions/setIcon.js index 543eaab..42ed325 100644 --- a/src/background/functions/setIcon.js +++ b/src/background/functions/setIcon.js @@ -20,15 +20,17 @@ const browser = require('webextension-polyfill'); const setIcon = async (tabId, active = true, changeTitle = false) => { + const option = process.env.EXT_PLATFORM === 'Safari' ? 'safari' : ''; + const iconObj = active ? { path: { - 16: browser.runtime.getURL('images/icons/icon16.png'), - 32: browser.runtime.getURL('images/icons/icon32.png'), - 48: browser.runtime.getURL('images/icons/icon48.png'), - 96: browser.runtime.getURL('images/icons/icon96.png'), - 128: browser.runtime.getURL('images/icons/icon128.png') + 16: browser.runtime.getURL(`images/icons/icon16${option}.png`), + 32: browser.runtime.getURL(`images/icons/icon32${option}.png`), + 48: browser.runtime.getURL(`images/icons/icon48${option}.png`), + 96: browser.runtime.getURL(`images/icons/icon96${option}.png`), + 128: browser.runtime.getURL(`images/icons/icon128${option}.png`) }, tabId } diff --git a/src/images/icons/icon128safari.png b/src/images/icons/icon128safari.png new file mode 100644 index 0000000000000000000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<$g3q#$h5!Hn literal 0 HcmV?d00001 diff --git a/src/images/icons/icon32safari.png b/src/images/icons/icon32safari.png new file mode 100644 index 0000000000000000000000000000000000000000..b10138ff46b8a08f327ea52be52c7eade9e36cbd GIT binary patch literal 676 zcmV;V0$crwP)B2&UL{cQR5<YJMG*%bLY*I{4!_e+;g7q zJ?D2`rVvFDC=?2+Xbm=F3)Z6x#klSlKH>@P;y&J0>TKG#0>Co#VJo(wx5TiTe&Q+a z#6Y+4Jq8M_7_``yEbv+p2WXA?yeBs$1o$oizn%DheZWLKxDb@CM?~$&@w){J>)L z%g%#b0EFc^l;gR&ln3A~&InoE5&t$OB;+xyY$d=1_6z%YnjYYW{L8aU)sk=&&nnbE z#z?*9c>ua_3JZkQ&>hDTA;|`@q7i^RIdCwJap6dv60(0GmNsHO7a$8}OgNs`VqK$# zvD(TC!uFY_qu7HDxYZ74a7vXN`QyrF5W$0R4$cC4fbE)dKUEO0M;l z0AMv9Hqrc1+~>5a0VE@Fxe4Z1g{^y*@&F{-CH(EG)%Y9sW_4N%04&G38q9}Oxl7gx zkZ1?qR4^XFfjk}63qUxU&!(6U3&(dZH3E>RPuRM@VqdL|6W@Pi2}5bC#=4&X0000< KMNUMnLSTYoz%FM1 literal 0 HcmV?d00001 diff --git a/src/images/icons/icon48safari.png b/src/images/icons/icon48safari.png new file mode 100644 index 0000000000000000000000000000000000000000..a3a41b14a7e6c99a4f6224430e2f80b8aa36dd73 GIT binary patch literal 901 zcmV;01A6?4P)LRMHmP0-RRV&bpq3&k%JmgB31}gTiUy5nR3co05D7QtSj?WwI=g3gX3p8i zAHL$u&Ue25f8O(*?NwE!Mz7aXh^uiMZpQVv5|`kD{_p=_4Zq`Ce1=2#GdIv6U+5JI z*xDz17j|POHfM4-e?*vRT@3yo!}3zExE<3b+bi&w+H49l`cg0h$Tr#DNdoS} zi3K3qWQSq_=lMVG5Z3TT#pQ89EMR>`L`rcsE?A15&n3R-4}2^vwVOI1)f4uZHs; zg&Wn9;T||E>?ga;U{@~@u!=hq>YXpF>o*m|NJhy%@I+$0GYZ!AT;vKki61iRe}hw* zF|v>=U|HJmsj-5KGh<|-WDXp}!@}kJLc^1IUD!=m@M0@=2`CY8g|La85>}kJ7taaT z(u>+rOGBG|V5&nS6>;mO&WR&A|XcrJi7qo_YD%t6##F{k^In6r9=R{JO}cxj3QDhfZ2Zd zc)E#18v(GxbXTWixM3WDwgPHQqc@&Q3EY(cxK=ki_K&zRHE5RtYV5_oh2;0=2AhTe z!guA>4C2RxLt{3kC7{M5LPla7`RCgNn6?1Izf|5dO#CN>tv-lZ2&l0KzX(0@jP_}G b3=8-VA1r+e1@5x600000NkvXXu0mjfvTdGB literal 0 HcmV?d00001 diff --git a/src/images/icons/icon96safari.png b/src/images/icons/icon96safari.png new file mode 100644 index 0000000000000000000000000000000000000000..2116efb90124b6a1748e992d4b2b0f9f1a0e63f2 GIT binary patch literal 1853 zcmV-D2g3M?P)4g5c=Q+twmAs@=(P%Nwg_iYo#qUMjLa{8e^rYouoC5 z$?@SohmJ|k?0wGOYps1|&KLeL%&b|L|8K9g_Fn(B*PiP2dIm8yH8t>WiCKbY;8}PP z&c`#c3M;W3OK~Q8IEIJu5dMXK;IG(?UD%6*vuU$3pMT+uO!cV4O1v8D@d~^Q=eCsh z-*E?ii`#LF5UV&-1$)3!;po@mRd@-`OIhG7J?z7s*nzFM3y&r#tfB|x6ksWyhjn<3 zxZ0oHW&sWOGp4a!^prhX5~Q>M&%s79tXwRHmB%&BG%-iTFmYm8czw1;HRmd^yP|2kw^coe<>&!3xDvn1P*z*qg!^%`#G^!xIbgH#a(B)Stap8WNHDPBsO4; zD{qq6M>!_p>x}1e_6u=!>Oyh|unsq5D5p(Ui#wpo)y$^kdJ=v&*5b=zhuIO`>J>d4 z7i0eAxK?b5PfpIIh>h4Fc9tED z=N#}Ku`aY@_U9!-{BQp*WjQXxTUxJODKf{0Z>^NxeAPG}kYflsfVYYl z;o4%0h%r3eVxC3FA;9%w?|j?*8edJ2Z&p$Z@CbgGF#qq0xnXR{5f3V{B*&)o$CC#?2usxS|J{(N>C-h zeHxsXHp^F32TrE(?S|!akq4_1R0;4G+}of6hw-zTX}32hr>h*SN>C-hA4EKNRE~&4 zE9y`;-8iwYDnXS1`^71Nqp}Q7tC@D8O~OaT1w1cxo&)X@L&+$djW^azd&P)lbd`PB zS(&QFc|l9W_&n;?jC)ldWqEaj{JU!3!dY!>OF1s?QbuL1n1}}rMeo7a8sy(qwyE)u zS@+Dijre853f+&d<5wbBzZ&nf@P;13@h`_cZ5`Ztj+l%~ck6MnAJy^iFgxQ8@1jPg(z6G|k z1J1~8JH@9K=Ou>##Ph*oS}VF;&CS8N1R&moneKpdQrj)!R=gHD1t5Yq*LT24sq7ng z!Y~fWEkK_u#ph&8JFG2xz)4?6s!J&Wh%n@hBR058wnc-Fj+PXl&zr@os-+z{tj&lw zdm7ON0f>0;4az&UuKhxMdbcrM5unfO@F(RRJjf2?{cSe5YXT5&IBr(n*(cjpEnW3< z>7oFAHt5C^^dT*b^@HfL0K~)F=d^Ps(I_@8@$r;h7og92d4oJN_;8Mfjf()pnGc`B zf2F_bpP#8sV?UT0~yhhJ`2q roQKbdcd!nL7s0PG+-ba7s1o3R?dAX$&4Jmt00000NkvXXu0mjf?;C_I literal 0 HcmV?d00001 diff --git a/src/manifest/safari.json b/src/manifest/safari.json index 4b846df..2bb344f 100644 --- a/src/manifest/safari.json +++ b/src/manifest/safari.json @@ -15,11 +15,11 @@ }, "browser_action": { "default_icon": { - "16": "images/icons/icon16.png", - "32": "images/icons/icon32.png", - "48": "images/icons/icon48.png", - "96": "images/icons/icon96.png", - "128": "images/icons/icon128.png" + "16": "images/icons/icon16safari.png", + "32": "images/icons/icon32safari.png", + "48": "images/icons/icon48safari.png", + "96": "images/icons/icon96safari.png", + "128": "images/icons/icon128safari.png" } }, "options_ui": { From 48b1dc70de491f27ec648760d6fa54169e0dee9a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Grzegorz=20Zaj=C4=85c?= Date: Wed, 19 Jul 2023 16:19:07 +0200 Subject: [PATCH 2/2] #1302 Safari options menu change --- src/optionsPage/optionsPage.html | 41 +------------------ src/views/menuViews/normal.html | 40 ++++++++++++++++++ src/views/menuViews/safari.html | 34 +++++++++++++++ webpack/development/optionsPage.dev.config.js | 4 +- webpack/production/optionsPage.prod.config.js | 4 +- 5 files changed, 81 insertions(+), 42 deletions(-) create mode 100644 src/views/menuViews/normal.html create mode 100644 src/views/menuViews/safari.html diff --git a/src/optionsPage/optionsPage.html b/src/optionsPage/optionsPage.html index c888991..22a9634 100644 --- a/src/optionsPage/optionsPage.html +++ b/src/optionsPage/optionsPage.html @@ -46,46 +46,7 @@
- + <%= require.context('html-loader!../views/menuViews', false, MENU_VIEW_REGEXP)(MENU_VIEW_FILENAME).default %>
    diff --git a/src/views/menuViews/normal.html b/src/views/menuViews/normal.html new file mode 100644 index 0000000..74a66ad --- /dev/null +++ b/src/views/menuViews/normal.html @@ -0,0 +1,40 @@ + \ No newline at end of file diff --git a/src/views/menuViews/safari.html b/src/views/menuViews/safari.html new file mode 100644 index 0000000..c6673f2 --- /dev/null +++ b/src/views/menuViews/safari.html @@ -0,0 +1,34 @@ + \ No newline at end of file diff --git a/webpack/development/optionsPage.dev.config.js b/webpack/development/optionsPage.dev.config.js index b3a5a81..3a944f1 100644 --- a/webpack/development/optionsPage.dev.config.js +++ b/webpack/development/optionsPage.dev.config.js @@ -113,7 +113,9 @@ const optionsPageDevConfig = { OPTIONS_VIEW_FILENAME: process.env.EXT_PLATFORM === 'Safari' ? JSON.stringify('./safari.html') : process.env.EXT_PLATFORM === 'Firefox' ? JSON.stringify('./firefox.html') : JSON.stringify('./normal.html'), OPTIONS_VIEW_REGEXP: process.env.EXT_PLATFORM === 'Safari' ? /safari\.html$/ : process.env.EXT_PLATFORM === 'Firefox' ? /firefox\.html$/ : /normal\.html$/, PININFO_VIEW_FILENAME: JSON.stringify(`./${process.env.EXT_PLATFORM.toLowerCase()}.html`), - PININFO_VIEW_REGEXP: BrowserRegExps[process.env.EXT_PLATFORM.toLowerCase()] + PININFO_VIEW_REGEXP: BrowserRegExps[process.env.EXT_PLATFORM.toLowerCase()], + MENU_VIEW_FILENAME: process.env.EXT_PLATFORM === 'Safari' ? JSON.stringify('./safari.html') : JSON.stringify('./normal.html'), + MENU_VIEW_REGEXP: process.env.EXT_PLATFORM === 'Safari' ? /safari\.html$/ : /normal\.html$/ }), new HtmlWebpackPlugin({ chunks: ['optionsPage', 'optionsPageStyles', 'contentPageStyles'], diff --git a/webpack/production/optionsPage.prod.config.js b/webpack/production/optionsPage.prod.config.js index a780427..a2098d1 100644 --- a/webpack/production/optionsPage.prod.config.js +++ b/webpack/production/optionsPage.prod.config.js @@ -118,7 +118,9 @@ const optionsPageProdConfig = { OPTIONS_VIEW_FILENAME: process.env.EXT_PLATFORM === 'Safari' ? JSON.stringify('./safari.html') : process.env.EXT_PLATFORM === 'Firefox' ? JSON.stringify('./firefox.html') : JSON.stringify('./normal.html'), OPTIONS_VIEW_REGEXP: process.env.EXT_PLATFORM === 'Safari' ? /safari\.html$/ : process.env.EXT_PLATFORM === 'Firefox' ? /firefox\.html$/ : /normal\.html$/, PININFO_VIEW_FILENAME: JSON.stringify(`./${process.env.EXT_PLATFORM.toLowerCase()}.html`), - PININFO_VIEW_REGEXP: BrowserRegExps[process.env.EXT_PLATFORM.toLowerCase()] + PININFO_VIEW_REGEXP: BrowserRegExps[process.env.EXT_PLATFORM.toLowerCase()], + MENU_VIEW_FILENAME: process.env.EXT_PLATFORM === 'Safari' ? JSON.stringify('./safari.html') : JSON.stringify('./normal.html'), + MENU_VIEW_REGEXP: process.env.EXT_PLATFORM === 'Safari' ? /safari\.html$/ : /normal\.html$/ }), new HtmlWebpackPlugin({ chunks: ['optionsPage', 'optionsPageStyles', 'contentPageStyles'],