How to get Dark mode on School Chromebook Introduction 

Dark Mode on Chromebook

To illustrate how you can enable the dark mode in Chrome OS, we’ll walk through how to  enable the flag and show a few apps that are already using the feature. Enable the Flags Open the  Chrome://flags page and search for “dark mode.” If you are already on the Dev or Beta channel,  then the “Enable Dark Mode” flag should appear in the list of options. You’ll also notice that  there is a new flag called “Show the overflow menu in the Omnibox.

To summarize what is happening with the flag: The flag enables the dark mode by hiding the  Chrome UI elements and replacing them with black bars that look like the Chrome OS  background image. The flag replaces the UI with an extension, which provides more information  about the flag’s purpose. This extension uses Chrome’s “Overflow Menu” API to display the  “More Actions” menu. The extension, which we will see shortly, is available on GitHub. It  currently includes five different actions.

Although this may be true for other apps as well, for our purposes we’ll use a custom app to  demonstrate how to use the flag. Create a Chrome Extension To create our extension, use the  command-line tool, chrome-extension-tool. Select the “Create New” option. Enter the name of  the extension (I named it dark mode), and then click “OK.” A new folder named dark mode will  appear in your extensions folder. This is where you will put the code that implements your  extension.

Change the Chrome OS Wallpaper 

To set a background image, click the “Choose Wallpaper” button in the upper-left corner. Then  select an image from the wallpaper’s gallery. The default image, “Wallpaper light. jpg,” will  look like Figure 4. After selecting the image, click the “Apply” button. The “Wallpaper” settings  are stored for the current profile. To view the profile name, use the following command:  chrome://settings/user profiles to display the user’s profile name, use this command: Use the  command-line tool to build the extension.

Undeniably, the most important part of any Chrome extension is the extension manifest file. This  file tells Chrome which permissions your extension requires and what extensions are allowed to  call into your extension code. In our case, we will only allow our extension to call into our own  extension code. Open your manifest file in a text editor and add this line to the top of the file:  {“name”: “dark mode”, “description”: “Dark Mode”} We’ll also need to provide a short  description and name for the extension, so change the value for “description” to something that  describes the purpose of the extension.

As has been noted by many other users, we will not be using the overflow menu API in this  extension. Instead, we will only be using the Chrome’s native API, which means we will not  need any permission. The following lines are all that we need to get started with our extension:  chrome. Manifest: { “name”: “dark mode”, “description”: “Dark Mode”, “manifest version”: 2 }  chrome. Runtime: {“name”: “dark mode”, “description”: “Dark Mode”, “manifest version”: 2} Chrome. Overflow menu: {“name”: “dark mode”, “description”: “Dark Mode”, “manifest  version”:

Change the Browser Theme 

As has been demonstrated elsewhere on the web, it is possible to change the overall theme for  Chrome OS. To do this, use the command-line tool to change the “wallpaper color” value to  black. In the terminal, type this command: echo “black” > ~/.config/system-wide/colors.ini If  you want to set a different color, try typing “black” in place of “black” above. Save the file and  exit the terminal. Now, try opening a Chrome browser window. You should see the black  wallpaper with the default Chrome color scheme.

Moreover, if you go back to the command-line and type “cat ~/.config/system-wide/colors.ini”  you should see “black” in the file. Change the User Interface Style Now that we have changed  the browser theme, it is time to change the user interface style. To do this, use the command-line  tool to change the “system UI style” value to “light”. In the terminal, type this command: echo  “light” > ~/.config/user-local/system UI style.

In this case, we want to have our extension have a dark UI. Therefore, you can remove “light”  from the system UI style setting. Save the file and exit the terminal. Now, open a new Chrome  browser window. You should see a dark UI with a light background. Enable Dark Mode in the  Chrome Extension The final step before you run your extension is to tell Chrome that you would

like the dark mode to be enabled when you launch the browser. To do this, add the following line  to the end of the manifest file: “permissions”.

Adjust Site Setting 

When running the Extension, the final step before we are ready to run our extension is to tell  Chrome how to run the extension. To do this, go back into the manifest file and add the  following line just above the permission line: “chrome URL overrides”: {“new tab”: “https://my”, “google-chrome”: “”, “update URL”:  “https://my-site-address.

And then, change “” to match your site’s domain. Save the file and  exit the terminal. Now, open a new Chrome browser window and you should see your site as a  new tab. To verify that you have correctly implemented the extension, click the “hamburger  icon” (three dots) in the top right corner of the browser. This will open the overflow menu.

Naturally, the hamburger icon is dark Gray. However, it should turn into a dark black when you  select the “dark mode” option. If everything is set up correctly, then you should be able to toggle  between the light and dark mode when opening new tabs.

The following screen capture shows the extension in the light mode and the extension in the dark  mode. The following screen capture shows the extension in the light mode. Note that the  extension icon in the upper-right corner of the browser is now light. As you can see, the  extension is not working as expected. This is because we have not implemented the proper  Chrome API yet.

Equally important, you have not configured the extension to automatically update, so there is no  way to know when the site has updated. Fortunately, it is very easy to add the missing pieces to

make the extension work properly. Let’s implement the necessary API first, then we will add  auto-update to the extension. First, we need to get a reference to the browser’s window object.  To do this, open the manifest file again and change the “background” permission to “tab”:  “background”:

Dark Mode on Chromebook

Install the Dark Reader Extension 

To run the dark mode, we need to install an extension called “dark reader”. However, there are a  few other third-party extensions that you can use to simulate the dark mode experience. The most  popular option is called “dark reader”. To install it, go to your extensions page and click the  “Add extension” button. The following screen capture shows how to install the extension. You  should see a new item in the extensions list titled “dark reader”.

Furthermore, you should see that it has been added to the Chrome Extensions panel. Now, you  just need to enable it. In the extension settings, make sure that “Enable for Chrome” is checked.  Then, scroll down to the bottom of the list and click “enable”. The next screen capture shows the  extension enabled. Note that the extension is greyed out in the extensions panel.

This means that the extension is not installed. This is because we have not yet implemented a  way to tell the extension when the site has been updated. However, you can turn the extension on  in the extension list. Now, you can open the extension and verify that the dark mode is working  correctly.

Certainly, you should see dark icons in the upper-right corner of the browser. The screen capture  shows how to open the extension and check that it is installed and working correctly. Now, let’s  get back to the extension that we need to install first. In your terminal, run the following  command: As you can see, the command installs the extension. This is a simple one-line  command. As I mentioned earlier, there are many other extensions that will simulate the dark  mode experience. You can find them at

store/search/dark+reader?hl=en. The dark reader extension works great for a demo.


Conclusion In this tutorial, we created our first Chrome Extension for dark mode on Chrome OS.  In the next post, we will go over some of the other ways that you can customize the look and feel  of Chrome OS.

Moreover, in the final post, we will cover how to make extensions run automatically after you  log in. Finally, if you want to learn more about how to create your own extensions, take a look at  our free course: How to Build a Chrome Extension. Summary In this tutorial, we created our first  Chrome Extension for dark mode on Chrome OS. We started by adding an icon and a short  description to the manifest file.

Then, we added a listener to the browser’s “on Message” event. Next, we added the necessary  background script that uses a web API call to toggle between light and dark mode. In the  background script, we used a simple switch statement to determine which theme mode to use. To  make the extension work correctly, we had to implement the Chrome API. Specifically, we had  to make use of chrome tabs. execute Script. Then, we were able to add a listener to the window  object.


Leave a Reply

Your email address will not be published.