The March 2017 update to ArcGIS Online includes a new feature called Shared Themes that lets an administrator set a logo and a palette of colors that can be used to apply consistent branding to web apps created by members of the organization.
Having an administrator configure a shared theme for your organization is the best way for most story map authors to apply branding to their stories; however, some authors may want to apply their organization’s theme colors in a different way or personalize the theme colors for individual stories.
Before the March 2017 update, the only way to use custom colors for a Map Series or Map Journal story was to download the app from GitHub, modify the code, and host the app yourself. But, as part of the work to support shared themes in these apps, the theme color values are now exposed as properties in the story configuration JSON. This means you can now specify theme colors for Map Series and Map Journal stories hosted on ArcGIS Online by editing the story JSON using a tool like ArcGIS Online Assistant.
WARNING #1 — Editing JSON can break your story!
If you’ve never edited story map JSON before it’s wise to first try it a few times on a test story until you’re comfortable with the procedure. If you choose to edit JSON for a published story, be aware of the risk you are taking and be sure to copy and save its original JSON in a text file in case something goes wrong.
WARNING #2 — If you’re not a web designer (or working with one) we strongly recommend you stick with one of the themes provided.
Here’s an example of the JSON that stores the theme for your story. The parameters you see will depend on the story type and layout (Map Series tabbed layout, Map Journal floating panel layout, etc.).
To set theme colors for your story…
- Open ArcGIS Online Assistant and log into your ArcGIS account.
- At the top click I want to…View an item’s JSON.
- In the left panel, find the story map you want to customize. These instructions are for Map Journal and Map Series stories only.
- In the Data section of the right panel, look for
themein the JSON (as shown above). As mentioned above in warning #1, now is a good time to Copy the original JSON and save it in a text file in case something goes awry. If you don’t see the
theme, see the note at the end of this post.
- Click Edit (the pencil button) to start editing the JSON.
nameproperty of the theme. We recommend you do not edit the
namein any other way.
- Edit the properties of the theme as you like using any valid color specification method like hex color codes, HTML color names, or RBGa values (if you need transparency).
- Use the Save button at the top of the Data section to save your changes.
- View your story or open it in builder (if it’s already open, reload the page) to see your shiny new theme colors!
Here are some general notes and tips for configuring theme properties:
- You can adjust the transparency of the floating panel in Map Journal using the
panelOpais not set, the floating panel will be 80% opaque.
- You can adjust the transparency of the description panel in Map Series (tabbed or bulleted layout only) by using an RGBa color value.
blackand controls the appearance of some minor visual elements like the arrows in the legend header and dot navigation strip.
- Since you are likely using your own logo if you are customizing theme colors you can ignore
You’ve edited the theme, now what?
Back in the builder under Settings > Theme you’ll see the organization theme (if configured by your administrator) and your modified theme, which is shown as the Current Theme since it’s currently applied to the story.
At this point, if you choose a theme other than Current Theme and save the story, your modified theme will not be available next time you load the story in builder. You’ll need to use the procedure above to edit the theme colors again.
What if you don’t see JSON for the theme?
If you don’t see
theme in your story JSON
settings, it’s likely because you’ve never changed the theme of your story. Just choose a different theme in Settings > Theme, save your story, then refresh the JSON view in ArcGIS Online Assistant by clicking the item name in the left panel. This will write the colors to the JSON so you can edit them. Now you can proceed with the steps above.