Can you Change a styles.CSS var from a Chrome Extension Popup

2022.01.23 12:54 Tanquen256 Can you Change a styles.CSS var from a Chrome Extension Popup

The styles.css injection works using the Wider button and the --ptwidth var is passed the value given (310) in the styles.CSS but I can't get the document.documentElement.style.setProperty to change it.
Are styles.CSS variables only usable inside the styles.CSS, they can not be written to from js script?
At the very least I'd like to be able to enter a new value in the textbox and then use the existing Wider button to load the updated styles.css but it would be nice to have it auto update and maybe even use the slider. I've found some examples using sliders and changing the background color in real time but not from a Chrome Extension Popup.
manifest:

 { "manifest_version": 3, "name": "Hellper", "description": "Extension", "version": "0.1", "icons": { "16": "logo_16_T.png", "48": "logo_48_T.png", "128": "logo_128_T.png" }, "action": { "default_icon": "logo_16_T.png", "default_popup":"popup.html" }, "permissions": ["scripting", "tabs", "activeTab"], "host_permissions": [""], "content_scripts": [{ "js": ["jquery-2.2.0.min.js", "popup.js"], "matches": ["https://www.google.com/*", "https://en.wikipedia.org/*""] }] } 
popup.html:
    Popup       
Project/Task Width Wonderful Extension
Please enter new width :
styles.css:
 :root { --ptwidth: 310px } .quixote .qx-grid .editor_grid tbody tr td input, .quixote .qx-grid .editor_grid tbody tr td .input-group { /*max-width: 450px !important; min-width: 450px !important;*/ max-width: var(--ptwidth) !important; min-width: var(--ptwidth) !important; 
popup.js:
 $(document).ready(function() { $('.reset').click(function() { chrome.tabs.query({currentWindow: true, active: true}, function (tabs){ var activeTab = tabs[0]; chrome.scripting.removeCSS({ target: { tabId: activeTab.id }, files: ["styles.css"] }); }); }) $('.format').click(function() { chrome.tabs.query({currentWindow: true, active: true}, function (tabs){ var activeTab = tabs[0]; chrome.scripting.insertCSS({ target: { tabId: activeTab.id, allFrames: true }, files: ["styles.css"] }); }); }) }) document.addEventListener('DOMContentLoaded', documentEvents , false); function myAction(input) { alert("The entered data is : " + input.value); document.documentElement.style.setProperty('--ptwidth', 246); } function documentEvents() { document.getElementById('ok_btn').addEventListener('click', function() { myAction(document.getElementById('name_textbox')); }); } 
submitted by Tanquen256 to chrome_extensions [link] [comments]


2022.01.23 12:54 TiengAnh A crab using an upside down jellyfish to defend itself against predators

A crab using an upside down jellyfish to defend itself against predators submitted by TiengAnh to ourbeautifulmachines [link] [comments]


2022.01.23 12:54 Cameraside H: QE 15c Harpoon W: Q heavies (non legacy) offers

submitted by Cameraside to Market76 [link] [comments]


2022.01.23 12:54 Minute-Stand1985 ‼️FREE 1x Freaky Apez 🐵 NFT + 25 WL spots 💵 UPVOTE ⬆️ + drop your ETH addy 🔥Check comments section 👇

‼️FREE 1x Freaky Apez 🐵 NFT + 25 WL spots 💵 UPVOTE ⬆️ + drop your ETH addy 🔥Check comments section 👇 submitted by Minute-Stand1985 to NFTExchange [link] [comments]


2022.01.23 12:54 WOLFTIGERSHARK Booking at 11 months time?

What time does the 11 month booking window open? Hopefully that question makes sense (like 6 am or something) TIA!
submitted by WOLFTIGERSHARK to dvcmember [link] [comments]


2022.01.23 12:54 Dry-Championship7634 Hello Fellow Struggle Mates

Hello Fellow Struggle Mates Please consider taking my survey focusing on measuring Highschool students during the 2020-2021 pandemic and their cybersecurity awareness. The goal of my research is to measure the impact of online learning on students' cybersecurity, whether or not during that period it made students more vulnerable to malicious attacks and data breaches.
Cybersecurity Self Awareness Survey
Don't be afraid to share the survey with other students that were in high school during online learning.

Thank you <3
submitted by Dry-Championship7634 to APResearch [link] [comments]


2022.01.23 12:54 squidly413 Is there a mod for this gas tank icon?

Is there a mod for this gas tank icon? submitted by squidly413 to projectzomboid [link] [comments]


2022.01.23 12:54 redmondcigar Central Virginia tiny dead bugs when it’s cold outside

Central Virginia tiny dead bugs when it’s cold outside submitted by redmondcigar to whatsthisbug [link] [comments]


2022.01.23 12:54 MrBlueAnimations itch.io demo go brrrrrrrr

itch.io demo go brrrrrrrr submitted by MrBlueAnimations to DaniDev [link] [comments]


2022.01.23 12:54 Mikrofal Mega Aerodactyl - 4430 9964 0970 ASAP

submitted by Mikrofal to PokemonGoRaids [link] [comments]


2022.01.23 12:54 MatchCaster [Post-Match thread] Arsenal vs Burnley

[Premier League - 2021/2022] Arsenal 0-0 Burnley Match Info:
Lineups:
Arsenal - 4-1-4-1
Starting XI: Aaron Ramsdale, Ben White, Rob Holding, Gabriel Magalhães, Kieran Tierney, Albert Sambi Lokonga, Bukayo Saka, Martin Ødegaard, Emile Smith Rowe, Gabriel Martinelli, Alexandre Lacazette
Substitutes: Bernd Leno, Nuno Tavares, Calum Chambers, Charlie Patino, Omari Giraud-Hutchinson, Salah Oulad M'Hand, Ryan Alebiosu, Mika Biereth, Edward Nketiah
Coach: Mikel Arteta
Burnley - 4-4-2
Starting XI: Nick Pope, Connor Roberts, James Tarkowski, Ben Mee, Erik Pieters, Aaron Lennon, Ashley Westwood, Josh Brownhill, Dwight McNeil, Jay Rodriguez, Matěj Vydra
Substitutes: Wayne Hennessey, Matthew Lowton, Kevin Long, Phil Bardsley, Nathan Collins, Bobby Thomas, Jack Cork, Dale Stephens, Jóhann Guðmundsson
Coach: S. Dyche
Match Stats:

Arsenal 0 - 0 Burnley
76% Ball Possession 24%
20 Total Shots 8
5 Shots On Target 1
8 Shots Off Target 5
7 Blocked Shots 2
13 Shots Inside Box 4
7 Shots Outside Box 4
12 Corner Kicks 4
0 Offsides 2
9 Fouls 13
0 Yellow Cards 2
0 Red Cards 0
1 Goalkeeper Saves 5
629 Passes 205
551 (88%) Accurate Passes 134 (65%)
Match events
0' KICKOFF!
25' Yellow Card for A. Westwood (Burnley)
30' Yellow Card for J. Brownhill (Burnley)
77' Substitution: E. Nketiah for E. Smith Rowe (Arsenal)
83' Substitution: J. Guðmunds­son for J. Rodriguez (Burnley)
90' Match whistled off
Player Match Stats
Arsenal
Player Rating Mins Shots Tackles Passes Duels Dribbles
Kieran Tierney 7.3 87 1 0 74 3 0
Martin Ødegaard 7.3 87 3 3 43 10 0
Aaron Ramsdale 7.2 87 0 0 30 0 0
Bukayo Saka 7.2 87 3 1 29 19 11
Rob Holding 7 87 1 0 91 10 0
Gabriel Magalhães 7 87 1 0 90 13 0
Emile Smith Rowe 7 77 1 0 40 3 1
Ben White 6.9 87 0 2 85 10 0
Alexandre Lacazette 6.9 87 2 1 21 5 2
Gabriel Martinelli 6.7 87 1 0 37 8 0
Albert Sambi Lokonga 6.6 87 0 0 50 8 0
Edward Nketiah 6.3 10 0 0 5 3 2
Burnley
Player Rating Mins Shots Tackles Passes Duels Dribbles
Nick Pope 7.7 87 0 0 26 1 0
Connor Roberts 7.2 87 0 1 15 5 0
James Tarkowski 7.2 87 0 1 14 9 0
Ashley Westwood 7.2 87 0 0 30 5 0
Dwight McNeil 7.2 87 2 2 12 12 6
Erik Pieters 7 87 1 4 21 13 0
Ben Mee 6.9 87 1 1 20 4 0
Jay Rodriguez 6.9 83 1 1 14 14 2
Matěj Vydra 6.9 87 0 2 15 13 1
Aaron Lennon 6.6 87 0 1 11 3 0
Josh Brownhill 6.6 87 0 3 21 10 0
Jóhann Guðmundsson 0 4 0 0 0 3 0

[ All data provided by MatchCaster ^(*, a next level football threading bot - fully configurable and customized threads controlled by moderators of this subreddit.
submitted by MatchCaster to premmemes [link] [comments]


2022.01.23 12:54 Crytpocurency WATCH OUT for THIS DATE IN CRYPTO !!! ⚠️ CRYPTO will be impacted BIG TIME !! 🔥 (YouTube Video: Crypto ZEUS)

WATCH OUT for THIS DATE IN CRYPTO !!! ⚠️ CRYPTO will be impacted BIG TIME !! 🔥 (YouTube Video: Crypto ZEUS) submitted by Crytpocurency to Cryptolandia [link] [comments]


2022.01.23 12:54 PineTree00 Auxiliary fuel tank

So I own an 07 civic sedan lx that I absolutely love. In the summer I regularly drive it on 200+ mile trips (at least once a month). I already have great mileage but I just want to do this because why the hell not lol. Obviously it will have to go in the trunk but that doesn’t matter to me. My trunk is mostly a space for tools and crap that should be in my garage anyway and there’s plenty of storage in the back seats. I have no interest in any performance mods for my civic since I rarely take it above 75mph and don’t need quick acceleration or vtec, so this is the kinda mod that appeals to me.
Has anyone ever tried this before on a civic lol? Or perhaps on another Honda? As for capacity I’d like at least another 11 gallons.
Side note: I know this is going to be very involved but I don’t care lol. That’s why I’m planning it now so I can do it in the summer.
submitted by PineTree00 to civic [link] [comments]


2022.01.23 12:54 mepper When Germany allowed school children to stop taking religious classes and start taking secular ethics classes, students who took the secular ethics class were found, years later, to be no less ethical than their counterparts in the religious education classes

submitted by mepper to science [link] [comments]


2022.01.23 12:54 colorful_candi1 Wanna lick my sweet feet?

Wanna lick my sweet feet? submitted by colorful_candi1 to FootFetishExperiences [link] [comments]


2022.01.23 12:54 rejectedfreak Haha seggs bonk horny jail dominant gf

Please laugh now 💀
submitted by rejectedfreak to teenagers [link] [comments]


2022.01.23 12:54 abjinternational Scrivere un Fumetto - Scrittura Creativa Vol. 6

submitted by abjinternational to udemyfreebies [link] [comments]


2022.01.23 12:54 AnimisticBolt Suggest: Uber/Uber Eats Passes for Ruby and Above ?

Hi,
I would like to propose Uber Eats Passes for those who aren’t using Netflix/Spotify. Crypto.com could consider on adding Uber Pass/Uber Eats Pass.
Considering the pandemic a lot of people will be happy about this.
There should be more options in these tiers.
Ruby should receive 2 options and may select 1. Jade and Above should receive 3 options could Select 2.
submitted by AnimisticBolt to Crypto_com [link] [comments]


2022.01.23 12:54 life_sucks7 i don’t think i can do this anymore

i'm 20 years old lesbian. i'm so fucking tired of living in this shit abusive household and this fucking homophobic country , i'm struggling with depression and i don't feel like i can do it . i don't even leave the house and if i did my father gonna kill me so i'm stuck between four walls for 20 fucking years and i can't even get a job so i can have money and runaway as fast as i can . i looked for solutions i didn't find shit it's feels impossible to leave this shit hole. i'm so exhausted i looked for every online shit so i can make money and leave but nothing works i don't think there's a way out. i don't want to wake up tomorrow i can't do it anymore i'm so tired i just wanna feel peace
submitted by life_sucks7 to mentalhealth [link] [comments]


2022.01.23 12:54 alex_xela0 I found this tiny but interesting detail in rdr2 while browsing through the catalog. Explanation in comment.

I found this tiny but interesting detail in rdr2 while browsing through the catalog. Explanation in comment.

https://preview.redd.it/k8tjhk9ylgd81.png?width=1792&format=png&auto=webp&s=4a8da5aaba02cd9282e94e4a10aa543295da8f8a
submitted by alex_xela0 to reddeadredemption2 [link] [comments]


2022.01.23 12:54 HugeMud Rhinohazard Reactions back at it again

Rhinohazard Reactions back at it again submitted by HugeMud to SuperMegaShow [link] [comments]


2022.01.23 12:54 Jokesterr24 I woke up at 3 am last night thinking about Brady.

I’m nervous AF. I wanna win so badly.
submitted by Jokesterr24 to LosAngelesRams [link] [comments]


2022.01.23 12:54 johnnycolemanart Acrylic landscape of Paynes Prairie Preserve State Park in Florida I did.

Acrylic landscape of Paynes Prairie Preserve State Park in Florida I did. submitted by johnnycolemanart to painting [link] [comments]


2022.01.23 12:54 adyo Help please: Crate of tomatoes knocked into chicken coop - how do I get it out!? (FS22)

Help please: Crate of tomatoes knocked into chicken coop - how do I get it out!? (FS22) Hi, I'm new to this and occasionally make mistakes, but far more often, the physics of the game go wild on me. I was picking up a crate of tomatoes and they went flying into this chicken pen and now I can't retrieve them. Are they gone forever? (on a server with multiplayer friends so I can't use any cheats or anything). It's on No Man's Land.

https://preview.redd.it/h1zthll0mgd81.jpg?width=1920&format=pjpg&auto=webp&s=3071b663989f04e9316eb43da5872718ce4991b5
submitted by adyo to farmingsimulator [link] [comments]


2022.01.23 12:54 cbvv1992 🔥50% Off Code – $14.99-$17.49 Dog's Coat

🔥50% Off Code – $14.99-$17.49 Dog's Coat submitted by cbvv1992 to DealAndSale [link] [comments]


http://flower55.ru