aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/google-voice
diff options
context:
space:
mode:
authorLibravatar oc013 <101832295+oc013@users.noreply.github.com>2023-11-03 10:13:45 -0400
committerLibravatar GitHub <noreply@github.com>2023-11-03 08:13:45 -0600
commit48dcdaff46ce392a23a945bd96e28b473ae000b0 (patch)
tree862a1a534f13efacb51d503e49f8687f74c66567 /recipes/google-voice
parentfeat: add memos recipe (#445) (diff)
downloadferdium-recipes-48dcdaff46ce392a23a945bd96e28b473ae000b0.tar.gz
ferdium-recipes-48dcdaff46ce392a23a945bd96e28b473ae000b0.tar.zst
ferdium-recipes-48dcdaff46ce392a23a945bd96e28b473ae000b0.zip
Google Voice recipe add darkmode.css, fix message counts (#449)
Diffstat (limited to 'recipes/google-voice')
-rw-r--r--recipes/google-voice/darkmode.css161
-rw-r--r--recipes/google-voice/package.json3
-rw-r--r--recipes/google-voice/webview.js6
3 files changed, 165 insertions, 5 deletions
diff --git a/recipes/google-voice/darkmode.css b/recipes/google-voice/darkmode.css
new file mode 100644
index 0000000..ed61286
--- /dev/null
+++ b/recipes/google-voice/darkmode.css
@@ -0,0 +1,161 @@
1:root {
2 --dark-grey: rgb(24, 26, 27);
3 --dark-medium-grey: rgb(27, 30, 31);
4 --medium-grey: rgb(31, 34, 35);
5 --dark-green: rgb(23, 55, 53);
6 --grey: grey;
7 --light-medium-grey: rgb(140, 130, 115);
8 --light-grey: rgb(208, 204, 197);
9 --near-medium-white: rgb(192, 186, 178);
10 --near-white: rgb(232, 230, 227);
11 --basically-white: #EEE;
12}
13
14* {
15 transition: none !important;
16 animation: none !important;
17 filter: none !important;
18 -webkit-animation: none !important;
19 -moz-animation: none !important;
20 -o-animation: none !important;
21 -ms-animation: none !important;
22}
23
24::placeholder /* placeholder text */
25{
26 color: var(--grey)!important;
27}
28
29::-webkit-scrollbar {
30 width: 8px!important;
31}
32
33::-webkit-scrollbar-thumb {
34 background: var(--medium-grey)!important;
35}
36
37::-webkit-scrollbar-thumb:hover {
38 background: var(--dark-green)!important;
39}
40
41html,
42body,
43input,
44button,
45label,
46header, /* header bar */
47.mat-drawer-container, /* side icons */
48.gvMessagingView-thread-list, /* List of calls */
49.gvMessagingView-conversationListWrap, /* list of messages */
50.gvThreadDetails-messageListHeader, /* header when viewing a message */
51.gvMessageListHeader-subtitle, /* subtitle in message header */
52.gvThreadDetails-root, /* message view */
53.gvVoicemailPlayer-content, /* visual voicemail view */
54.gvCallSidebar-root, /* calling sidebar */
55.gvSettingsView-settingsNavBar, /* settings sidebar */
56.gvSettingsView-sections, /* settings body */
57#contact-list, /* calling sidebar contacts */
58.button, /* calling sidebar */
59.caption, /* calling sidebar */
60.dialpad-button-container, /* calling sidebar */
61md-menu-content,
62gv-availability-view,
63.gvRecipientPicker-chipsWrap, /* selecting to: when sending new msg */
64.gb_te, /* search box dropdown */
65div.mat-mdc-select-panel, /* settings recharge notification amount */
66.gvBillingView-header /* billing header */
67{
68 background-color: var(--dark-grey)!important;
69 border-color: var(--light-medium-grey)!important;
70 color: var(--light-grey)!important;
71}
72
73.gvThreadItem-selected, /* messages list item */
74.container, /* calls list items and also message text container */
75.mat-mdc-menu-panel /* context menus */
76{
77 background-color: var(--dark-grey)!important;
78}
79
80iframe,
81header form, /* Main search bar */
82header form input, /* Main search bar */
83header form button, /* Main search bar */
84.icon /* settings page icons */
85{
86 background-color: var(--medium-grey)!important;
87}
88
89.mdc-list-item--activated,
90.container.active, /* calls list items and also message text container */
91.gvThreadItem-selected /* message list selected item */
92{
93 background-color: var(--dark-green)!important;
94}
95
96.gvThreadItem-root:hover, /* messages list item */
97.gvThreadItem-root:focus, /* messages list item */
98.gvMessagingView-thread-list .container:hover /* calls list items */
99{
100 background-color: var(--dark-medium-grey)!important;
101}
102
103.mat-divider {
104 border-color: var(--light-medium-grey)!important;
105}
106
107.bubble /* message bubble */
108{
109 background-color: var(--dark-grey)!important;
110 color: var(--light-grey)!important;
111 border: 1px solid var(--light-medium-grey)!important;
112}
113
114input,
115textarea,
116header span[role="heading"],
117.mat-icon, /* general icon override */
118.navItemLabel, /* main nav labels */
119.mdc-list-item__primary-text, /* settings nav items */
120.mat-mdc-select, /* settings autorecharge text */
121.grey-900, /* various bolded items */
122.gvThreadItem-contacts, /* message list contact name */
123.phone-number-details, /* calling sidebar label */
124#contact-list ul li .info-container .name, /* calling sidebar contact list */
125.gvThreadItem-contacts, /* contact name in message list */
126.primary-text, /* call header name */
127.title, /* receiving calls button */
128.sectionTitle, /* settings title */
129.internalHeader, /* settings sub title */
130.header, /* settings sub title */
131.device-label, /* settings devices */
132.deviceLabel, /* settings devices */
133.details .name /* settings greeting label */
134{
135 color: var(--near-white)!important;
136}
137
138.status, /* various label text (message sender, timestamp etc) */
139.gvThreadItem-root, /* message list text */
140.container .thread-info,
141.call-as-label, /* calling sidebar label */
142#contact-list ul li .info-container .details,
143.latest-item-details, /* call timestamp */
144.secondary-text, /* call header subtext */
145.subheader, /* settings sub sub title */
146.internalSubheader, /* settings sub sub title */
147.device-details, /* settings device number */
148.deviceDetails, /* settings device number */
149.no-devices, /* settings devices */
150.notificationText /* settings web notifications */
151{
152 color: var(--near-medium-white)!important;
153}
154
155div[aria-label^="Unread"] .thread-info, /* unread missed calls */
156div[aria-label^="Unread"] .latest-item-details, /* unread missed calls */
157.gvThreadItem-unread /* unread message */
158{
159 color: var(--basically-white)!important;
160 font-weight: 900!important
161}
diff --git a/recipes/google-voice/package.json b/recipes/google-voice/package.json
index 3945c5a..0147b8d 100644
--- a/recipes/google-voice/package.json
+++ b/recipes/google-voice/package.json
@@ -1,9 +1,8 @@
1{ 1{
2 "id": "google-voice", 2 "id": "google-voice",
3 "name": "Google Voice", 3 "name": "Google Voice",
4 "version": "0.6.1", 4 "version": "0.6.2",
5 "license": "MIT", 5 "license": "MIT",
6 "repository": "https://github.com/BehindTheMath/franz-recipe-google-voice",
7 "config": { 6 "config": {
8 "serviceURL": "https://voice.google.com/u/0/", 7 "serviceURL": "https://voice.google.com/u/0/",
9 "message": "Google Voice gives you one number for all your phones, voicemail as easy as email, free US long distance, low rates on international calls, and many calling features like transcripts, call blocking, call screening, conference calling, SMS, and more." 8 "message": "Google Voice gives you one number for all your phones, voicemail as easy as email, free US long distance, low rates on international calls, and many calling features like transcripts, call blocking, call screening, conference calling, SMS, and more."
diff --git a/recipes/google-voice/webview.js b/recipes/google-voice/webview.js
index d589f28..c679aa0 100644
--- a/recipes/google-voice/webview.js
+++ b/recipes/google-voice/webview.js
@@ -18,13 +18,13 @@ module.exports = Ferdium => {
18 count = Ferdium.safeParseInt(el.textContent.replaceAll(/[ ()]/gi, '')); 18 count = Ferdium.safeParseInt(el.textContent.replaceAll(/[ ()]/gi, ''));
19 } else { 19 } else {
20 const countMessages = parseQuery( 20 const countMessages = parseQuery(
21 'gv-nav-tab[tooltip="Messages"] div[aria-label="Unread count"]', 21 'mat-nav-list a[gv-test-id="sidenav-messages"] span.navItemBadge',
22 ); 22 );
23 const countCalls = parseQuery( 23 const countCalls = parseQuery(
24 'gv-nav-tab[tooltip="Calls"] div[aria-label="Unread count"]', 24 'mat-nav-list a[gv-test-id="sidenav-calls"] span.navItemBadge',
25 ); 25 );
26 const countVoicemails = parseQuery( 26 const countVoicemails = parseQuery(
27 'gv-nav-tab[tooltip="Voicemail"] div[aria-label="Unread count"]', 27 'mat-nav-list a[gv-test-id="sidenav-voicemail"] span.navItemBadge',
28 ); 28 );
29 count = countMessages + countCalls + countVoicemails; 29 count = countMessages + countCalls + countVoicemails;
30 } 30 }