Recommended Posts

Admin Theme Boss

A light and clear theme based on Uikit 3

Features

  • Three unique color options
  • Beautiful typografy using Roboto Condensed
  • Extended breadcrumb with edit links
  • Extends AdminThemeUikit, you can continue using all AdminThemeUikit features
  • Option to activate theme for all users

Color Variants:

ProcessWire Blue

alt text

Vibrant Blue

alt text

Dark Black

alt text

Requirements

Requires AdminThemeUikit installed and activated.

Installation

  1. Make sure the above requirements are met
  2. Go to “Modules > Site > Add New“
  3. Paste the Module Class Name “AdminThemeBoss“ into the field “Add Module From Directory“
  4. Click “Download And Install“
  5. On the overview, click “Download And Install“ again
  6. On the following screen, click “Install Now“


alt text

Install manually

  1. Make sure the above requirements are met
  2. Download the theme files from GitHub or the ProcessWire Modules Repository.
  3. Copy all of the files for this module into /site/modules/AdminThemeBoss/
  4. Go to “Modules > Refresh” in your admin
  5. Click “Install“ on the “AdminThemeBoss“ Module

 

vibrant.png

  • Like 12

Share this post


Link to post
Share on other sites
Posted (edited)

@ryan I have published this theme on the modules repo with the class name AdminThemeUikit in the assumption, it would use my provided title (Admin Theme Boss) as url (and classname) – but now it's listed as https://modules.processwire.com/modules/admin-theme-uikit – what I did not intend. I fear this will lead to confusion, especialy when installing using the backend.

edit: Okay, I found out I am able to change the classname – but the url remains modules/admin-theme-uikit – which would probably be better if you or an admin could change it to modules/admin-theme-boss – Sorry for any inconvenience I might have caused.

This Question Remains: This theme is basically the same as your AdminThemeUikit with slight modifications of the config and of course updated CSS. I used the same classname but a different folder (AdminThemeBoss) on my system since I did not find a way to extend AdminThemeUikit to let existing modules (like AOS) keep using the hooks of AdminThemeUikit. I tried to extend AdminThemeUikit but then, the hooks would not have any effects. How could I use my own classname but still keep the modifications of AOS etc? Any suggestions on how to proceed with the classname? 

 

Edited by Noel Boss
Fixed classname

Share this post


Link to post
Share on other sites

Just a heads up, I did try to install the theme, but it really did a number on the admin side.185036520_ScreenShot2018-07-05at12_23_45PM.thumb.png.01191d868bb3f72587524c6ca4ad83dd.png

Ill have to revert back to a previous state with adminthemeui installed.

Share this post


Link to post
Share on other sites

Hi @louisstephens

I have just updated the GitHub repository with a possible fix. Could you try? You also need to select Uikit as the theme in your profile beforehand…

Share this post


Link to post
Share on other sites

adminboss.thumb.png.a3a659fab20a3a65a251d13afe341ae4.png

This looks so interesting that I had to install it but...

I tried the latest version from Github and the one from module directory.

Share this post


Link to post
Share on other sites

There was an issue with installations in subfolders – wire('config')->urls->AdminThemeUikit returned the subfolder twice, resulting in wrong css urls. The latest release 0.1.4 fixes that as well…

  • Like 1

Share this post


Link to post
Share on other sites

Looks really nice!

Just wondering about the approach you've taken - if this module is about styling changes to the core AdminThemeUikit couldn't the module just add a CSS file containing the style overrides and not reproduce all the AdminThemeUikit files?

  • Thanks 1

Share this post


Link to post
Share on other sites
10 hours ago, Robin S said:

just add a CSS file containing the style overrides and not reproduce all the AdminThemeUikit files

Thats not practical since the "overrides" would need to be at so many places. With Uikit you've got LESS where you inject your colors etc. at various places. You replace code, not just override it. Simple overrides would be much more complicated and and could potentially break on an updated base theme. Replacing the whole CSS makes sence. BUT, you're suggestion just triggered an idea: Publish it as a propper Module and replace the CSS of the AdminThemeUikit with a hook… This way, AdminThemeUikit would still be technically the Theme, but the CSS (and potentially JS) would be entierly replaced by the "Child" Theme. In this way, one would also not need to change Settings etc… Brilliant!

But I think, the required Method is not (yet) hookable… I guess it is hookable, since it's public…

  • Like 4

Share this post


Link to post
Share on other sites

Nice job @Noel Boss ! Already adopted, modified & installed !

I just tweaked it to get a Google look (controls), removed the transparency on dropdown and reversed the fonts and notes.

 

GoogleBoss.thumb.png.b6ad24e544f1481047356dc71a32b006.png

 

GoogleBoss2.thumb.png.a8a3e85785facc148977c7455f9ae9dd.png

  • Like 2

Share this post


Link to post
Share on other sites

Released 0.2.0 + 0.2.1

  • Theme is now a module extending AdminThemeUikit by replacing the CSS
  • This simplifies the installation, simply download the module and install it
  • Added extended breadcrumb with edit links
  • Added option to activate the theme for all users
  • Updated look of checkboxes and radios – thanks @flydev for inspiration
  • Release 0.2.1; Styled login form
  • Like 5

Share this post


Link to post
Share on other sites

Great work! I prefer the default uikit theme but just gave it a try and everything worked.

Here's a kickstartfile if you want to use PW Kickstart to try it out quickly using PW Kickstart:

Spoiler

<?php
/**
 * Sample Kickstartfile
 * 
 * @author Bernhard Baumrock, baumrock.com
 * @version 1
 * 
 * This file returns a php array with settings for the kickstart installer.
 * 
 * The installer instance is available as $this
 * You can access all methods of the installer, eg $this->randomPassword();
 */

$password = $this->randomPassword(16);

return [
  /**
   * url of the processwire installation zipfile
   * current master version: https://github.com/processwire/processwire/archive/master.zip
   * current dev version: https://github.com/processwire/processwire/archive/dev.zip
   * other versions: eg https://github.com/processwire/processwire/archive/3.0.34.zip
   */
  'pw' =>'https://github.com/processwire/processwire/archive/dev.zip',
    
  /**
   * which site profile to use
   * ---
   * options are:
   *  - a pw profile name, eg 'site-blank'
   *  - a local zip folder in the site root, eg 'myprofile.zip'
   *  - an url to a zip file, eg 'https://raw.githubusercontent.com/.../myprofile.zip'
   */
  'profile' => 'site-default',

  /**
   * installation settings
   * ---
   * here you can overwrite the default settings that are set in Kickstart.php
   * see the link below to toggle a list of all default settings
   */
  'settings' => [
    'timezone' => 368, // vienna
    
    // 'dbName' => 'yourdbname',
    'dbUser' => 'root',
    'dbPass' => '', //$this->randomPassword(),
    
    //'admin_name' => 'admin',
    //'username' => 'admin',

    // random password set on top of this file
    //'userpass' => $password,
    //'userpass_confirm' => $password,

    //'dbTablesAction' => 'remove',
  ],
  
  /**
   * here you can set an array of options that is sent to the recipes
   * this makes it possible to define some kind of master recipes hosted on
   * gitlab and execute them with custom settings
   */
  'recipesettings' => [
    'foo' => 'bar',
  ],

  /**
   * recipes that are executed after installation
   * those recipes will get downloaded to the /recipes folder and then executed in order of their filename
   */
  'recipes' => [
    // downloads file to /recipes/sample-recipe.php and executes it
    // 'https://gitlab.com/baumrock/kickstart/raw/master/assets/sample-recipe.php',

    // sample callback as recipe
    function() {
      // $this->msg('Installing AOS...'); // demo
      $aos = $this->installModule('AdminOnSteroids', 'https://github.com/rolandtoth/AdminOnSteroids/archive/master.zip');
      $this->wire->modules->saveConfig($aos, [
        'enabled' => 1,
        'enabledSubmodules' => ['FieldAndTemplateEditLinks'],
      ]);
      
      $tracy = $this->installModule('TracyDebugger', 'https://github.com/adrianbj/TracyDebugger/archive/master.zip');
      $this->wire->modules->saveConfig($tracy, [
        'superuserForceDevelopment' => 1,
        'editor' => 'vscode://file/%file:%line',
      ]);
      
      $this->installModule('AdminThemeBoss', 'https://github.com/noelboss/AdminThemeBoss/archive/master.zip');
    },
  ],
];

 

 

  • Like 3

Share this post


Link to post
Share on other sites

@Noel Boss thanks for this module. Installed without a problem. Guess it's not yet in the modules directory? What I don't get is what is Extended Breadcrumbs for? The theme is almost 18 MB in size, seems a lot for a few css files? Just for fun, I took uikit.vibrant.css file and used it in AdminThemeDefault config options (Layout + interface, Advanced) and got the look and feel without using your module. Or I miss something?

  • Like 1

Share this post


Link to post
Share on other sites

@matjazp The modules comes with all the source files required by the theme (less files etc) but what's actually included in the backend is only the uikit.variant.min.css file which is about 330k in size. It also needs some code to rewrite the css source file (the required method in AdminThemeUikit is not hookable) and a hook to extend the breadcrumb with edit links…

 

 

Share this post


Link to post
Share on other sites

I really love your Theme but I don't know if it is right to use it because the Uikit version you use, is outdated. Right now there is a RC17 version. Also I think Ryan made some additions in the AdminThemeUikit, do you plan to be on par, if something changes or is added?

  • Like 1

Share this post


Link to post
Share on other sites

Thanks @jmartsch – I am using the theme myself so I should keep it updated… Since the theme just replaces the CSS, this should normaly be no problem…

Just released 0.3.0 with uikit 3.0.0-rc.17 and a new way how CSS and the logo is injected (as actual theme config values for AdminThemeUikit instead of rewriting the html output)

I will release 0.3.1 soon with the latest AdminThemeUikit Changes incorporated (work in progress)

  • Like 2

Share this post


Link to post
Share on other sites

Thx for the heads-up noel. I just tried your theme again and found this little bug:

R3wvVc8.png

 

On 7/5/2018 at 5:58 PM, Noel Boss said:
  • Three unique color options
  • Beautiful typografy using Roboto Condensed
  • Extended breadcrumb with edit links
  • Extends AdminThemeUikit, you can continue using all AdminThemeUikit features

Very nice!

Why are there three colors? Could you describe a bit how you created thos color variants? What is necessary to add a new custom color? Is everything replaced by hand in the css? Or is there some less/sass files? The reason why I'm asking is because it would be great to have the option to change some colors just by selecting one.

  • Like 1

Share this post


Link to post
Share on other sites
40 minutes ago, Noel Boss said:

AdminThemeUikit Changes incorporated (work in progress)

Could you explain that a little bit more detailed, please? I just try to understand how your module works 🙂 

Share this post


Link to post
Share on other sites

It would be nice, if this theme would be selectable as an option on the user profile page instead of replacing the standard Uikit theme.

An option to use the normal unmodified AdminThemeUikit would also be good in my opinion.

Share this post


Link to post
Share on other sites

Hello Friends…

New Version 0.4.0 released. I try to answe a few questions.

On 10/9/2018 at 6:21 PM, bernhard said:

Could you explain that a little bit more detailed, please?

How the theme works:

The variations & Ryans work:

It uses the built in uikit feature to create themes. Theme variations can be defined in uikit/themes.json. In my case, I define 3(+1) themes: black, blue and vibrant blue.
These relate to "entry points" found under ./uikit/custom/antrypoint.less » like uikit/custom/pw.less or black.less or vibrant.less

Each one of these basically only defines the custom accent colors and include all other general variables and some overrides:

// uikit source
@import "../src/less/uikit.theme.less";

// main accent color:
// pw color
@theme-primary-color: #3584EA;
@theme-primary-color-rgba: rgba(53, 132, 234, 0.6);

// Original Theme
@import "../../AdminThemeUikit/pw/_import.less";

// AdminThemeBoss Custom Styles
@import "fonts/fonts.less";
@import "theme/main.less";

In the newest Version (0.4.0) I actually grab ryans code (uikit and other custom stuff) and include my own customizations (variables etc) after that, this should ensure that the theme stays as compatible as possible. Of yourse if ryan changes major stuff, this needs to be addressed sperately. The Main File is uikit/custom/theme/main.less

Ryans stuff can be found under ./AdminThemeUikit/ – it's a copy of the custom folder of his Module. There is a new ./upgrade-theme.sh that automates that stepp…

Compiling the css

Compiling is done using npm or yarn using webpack from the uikit folder. It's easy:

$ cd uikit
# grab node modules:
$ yarn
# compile
$ yarn compile-less
# or for development:
$ yarn watch

Injecting the css:

Before 0.3.0 I search and replaced Ryans CSS in the html using a hook. Since 0.3.0 i only set parameters of AdminThemeUikit:

cssURL and logoURL

1137887888_Screenshot2018-10-11at15_21_42.thumb.png.f49f8c8ea3762b377b798ed1fa821ef7.png

So no messing arround with unstable HTML…

Why not an actual Theme?

18 hours ago, jmartsch said:

It would be nice, if this theme would be selectable as an option on the user profile page instead of replacing the standard Uikit theme.

Tldr; For compatibility & flexibility reasons

Longer Version: Because if I make AdminThemeBoss an actual standalone theme, I lose compatibility with Ryans AdminThemeUikit … By only working on top of his theme,  all new features he includes will still (and instantly) be working with AdminThemeBoss without an upgrade because my theme is mostly only css. Also, I can not hook into his functions for example to extend the breadcrumb if I build my theme as a standalone theme.

Why these color variations?

On 10/9/2018 at 6:19 PM, bernhard said:

Why are there three colors?

Now there are 4 😉

» Black: Because I our basic Corporate Design is mostly black and white
» Processwire Blue: Because obvious I it would be cool to retain some relation to PW CD
» Bright Blue: To have something fresh and because I like it 😉
» And a new Happy Pink version because of C43H66N12O12S

  • Like 3

Share this post


Link to post
Share on other sites

Great, thx for the heads-up!

So that means it would be very easy to improve your module to use the default theme (by ryan) and adjust some variables via inputfields. These Inputfields could - in the easiest implementation - be regular text fields (one field for each adjustable less variable). Or it could be a textarea field where we can copy something like this:

@theme-primary-color: #3584EA;
@theme-primary-color-rgba: rgba(53, 132, 234, 0.6);

Just include a php less parser: https://github.com/oyejorge/less.php

$parser = new Less_Parser();
$parser->parseFile( '/var/www/mysite/ryansbasictheme.less' );
$parser->parse( '@theme-primary-color: #3584EA; @theme-primary-color-rgba: rgba(53, 132, 234, 0.6);' );
// the line above would take the inputfield values, it's just to show how easy it is to parse the less with custom php variables
$css = $parser->getCss();

Then we'd only have to tell the regular theme to take this new CSS as stylesheet. Maybe you could define this as option (color1, color2, color3, custom less).

And it would be easy to customize the admin for everybody very easily and fast - and without any source compilation. Ah, of course the creation of the CSS would have to be done once when changing values. It would be totally imperformant on every page load. 

 

50 minutes ago, Noel Boss said:

And a new Happy Pink version because of C43H66N12O12S2

If I understand that correctly: Congrats! 😉 🎉🎉

Share this post


Link to post
Share on other sites

@bernhard

On 10/9/2018 at 6:19 PM, bernhard said:

The reason why I'm asking is because it would be great to have the option to change some colors just by selecting one.

I agree that would be awesome. I thought about this as well but didn't force it because I'm not sure if this would work since the current process of compiling goes trough npm/yarn > webpack – there's probably a lot of magic going on there…

 

1 hour ago, bernhard said:

If I understand that correctly: Congrats! 😉 🎉🎉

Nothing special happened right now, but it's still a great hormone 😉 

 

Share this post


Link to post
Share on other sites
7 minutes ago, Noel Boss said:

Not sure if this would work since the current process of compiling goes trough webpack – there's probably a lot of magic going on there…

Doesn't sound like you are eager to try it out? 😉

Share this post


Link to post
Share on other sites
2 hours ago, bernhard said:

Doesn't sound like you are eager to try it out? 😉

Would love to, but it's not a priority for me right now and I don't have time. But since I documented how it works, I'm open to implement it if someone finds a way…

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By AndZyk
      With around 3,400 employees worldwide, IMS Gear develops and produces specific drive solutions for international customers. In addition to the focus on the automotive industry, the focus is on applications for industry and e-mobility concepts.
      Finding new employees is important for the day-to-day business of IMS Gear. For this reason our agency designconcepts developed a job portal, where potential employees can easily inform themselves about the company, the application process and find the job they are looking for. The website was build with help of the framework UIkit.
      jobs.imsgear.com
       
      Features:
      Job finder Job offer PDF Newsletter Fly-in information pages  
      Job finder
      Core of the website is the job exchange with the job finder. Here you get a list of all available jobs which you can filter by three main areas (categories, task areas and locations). Or you can type in anything in the search field and filter by various keys (for example ID, title, country and hidden tags). The job finder was build with jQuery Typeahead, which was really helpful in building this complex logic. If you want to know which job is the closest to you, you can sort them by distance.

       
      Job offer PDF
      Every job offer has a printable PDF version for newspapers or other job platforms. The job offer PDF can be created by checking a checkbox in the back-end and saving the page. The PDF will then be created with all needed fields of that page and DocRaptor. This workflow is really easy for editors and guarantees a consistent layout for all created PDFs.

       
      Newsletter
      If there is no job for you available at the moment, you can subscribe to a newsletter with your areas of interest. Then you will be notified daily if a job is available with your interests. Instead of using a separate newsletter tool, the nice module Newsletter Subscription was used to manage subscribers. The newsletter will be send via a shell script executed by a daily cron job.
       
      Modules used:
      Continents and Countries Front-End Page Editor Functional Fields Markup Sitemap XML Newsletter Subscription ProCache Repeater Matrix Tracy Debugger Upgrades Wire Mail SMTP  
      Regards, Andreas
    • By AndZyk
      S. Siedle & Söhne Telefon- und Telegrafenwerke OHG is one of the leading manufacturers of building communications technology in Germany and Europe. For a company of this size it is important to have a solid brand communication. For this reason our agency designconcepts developed a portal where the employees of the company as well as others who work with or have interest in their brand can find everything that is important for the brand Siedle.
      The website introduces the brand, provides informations for different topics (for example logos, typography, colors etc.) and has a large Media-Center with images, videos and documents. The website was build with the framework UIkit.
      brand.siedle.com
       
      Features:
      Repeater Matrix Protected Content Media-Center Cart Auotcomplete Search  
      Repeater Matrix
      The information pages are build with a Repeater Matrix field and have a two columns layout. To be even more flexible, a section is a content element containing two Repeater Matrix fields for each column. This maybe sound crazy at first but was no problem and made complex layouts possible. 😀

       
      Protected Content
      Not all of the informations are meant for guests, so we made it possible to protect each page, section and content element with a checkbox. If this checkbox is checked, the content will only be visible for logged-in users.
       
      Media-Center
      The core of the brand portal is the Media-Center. The Media-Center is actually a mirror of a separate digital assets management database where the client can manage images, videos and documents with a nice interface in a protected environment.
      All new assets will be synced via a shell script containing PHP and curl commands calling the API of the database. This script will be executed every 15 minutes via cron job. This way all of the assets are saved as pages in ProcessWire and we can expand them with our own logic and fields. Also for the unlikely case that the database is not available, the Media-Center would still work.
       
      Cart
      Inside the Media-Center you can add assets to your cart. This cart is for downloading selected assets or sharing them with others. A cart will be accessible for 30 days.
       
      Modules used:
      Admin Custom Files Continents and Countries Email Obfuscation (EMO) Front-End Page Editor Functional Fields Markup Sitemap XML ProCache Repeater Matrix Tracy Debugger Upgrades  
      Regards, Andreas
    • By benbyf
      I always seem to get this warning on every new install of PW on my Ubuntu 14 box with Digital Ocean. The servers are usually based in the UK and I was wondering if I should be adding something other than the below in the config? Is there a UK based locale code? Quick Google didnt come up with much.
      Warning: your server locale is undefined and may cause issues. Please add this to /site/config.php file (adjust “en_US.UTF-8” as needed): setlocale(LC_ALL,'en_US.UTF-8');
      Added to the config file:
      setlocale(LC_ALL,'en_US.UTF-8');  
    • By AndZyk
      The Katharinenhöhe is a rehabilitation clinic in the Black Forest (Germany) for teenagers, young adults and families with children who suffer from cancer. Our agency designconcepts was lucky to relaunch their website.
      Our goal was to unify the previous separated areas (families and teenagers/young adults) and provide a clear structure for potential patients. Also we wanted to show that the clinic is a nice place to live, despite the circumstances. We rebuild the website from scratch with the framework UIkit and used large images as well as videos.
      www.katharinenhoehe.de
       
      Features:
      Repeater Matrix Tour Contrast Theme Glossary Autocomplete Search Facebook  
      Repeater Matrix
      Most of the pages use a basic page template which have one Repeater Matrix field. This field has around 15 different content elements, so it is easy to build a page with different elements in various amounts.

       
      Tour
      On the site tour we build a image map with markers showing interesting places of the clinic. For this task the nice module Image Marker and the Marker component of UIkit came in handy. The tour is available on every page containing a marker.

       
      Contrast Theme
      For a better reading experience you can switch to a more contrasting theme of the website by clicking the theme switcher (on the top right). This is a separate stylesheet with darker color variables. The choice will be saved in a session variable and stays as long as the browser is opened.
       
      Glossary
      To explain complicated medical terms better, we highlight a set of terms in every textarea they occur and explain them with a tooltip. For this task we wrote a simple Textformatter module which looks for the terms in a page and replaces the terms with the tooltip.
      This tutorial by @benbyf helped me. Thank you! 😉
       
      Modules used:
      Color Email Obfuscation (EMO) Front-End Page Editor Functional Fields Image Marker Markup Sitemap XML Phone ProCache Repeater Matrix Tracy Debugger Upgrades  
      Regards, Andreas
    • By mjut
      Hello!
      I am trying to get some extra css-file into my admin templates. I managed to modify my admin.php to this:
      <?php namespace ProcessWire; require($config->paths->adminTemplates . 'controller.php'); echo "<link rel='stylesheet' type='text/css' href='" . $config->urls->templates . "css/admin.css'>"; By doing so, the css <link> is added to the very end of each parsed admin-html. (right AFTER the closing </body> tag.)
      That causes some trouble. e.g. the page tree is not displaying any more. Although, other pages are working - like the edit form of a page.
      My question: is there a correct way of adding my extra css to the admin area?
      Thanks for you help!
      Stephan