<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Paul Stanton on Medium]]></title>
        <description><![CDATA[Stories by Paul Stanton on Medium]]></description>
        <link>https://medium.com/@coffeepowered?source=rss-5d2d5205ed39------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*eTuAm4kqDv1kPC6odCqlyg.jpeg</url>
            <title>Stories by Paul Stanton on Medium</title>
            <link>https://medium.com/@coffeepowered?source=rss-5d2d5205ed39------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 29 May 2026 17:51:42 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@coffeepowered/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com" rel="hub"/>
        <item>
            <title><![CDATA[Which accessibility testing tool should you use?]]></title>
            <link>https://medium.com/pulsar/which-accessibility-testing-tool-should-you-use-e5990e6ef0a?source=rss-5d2d5205ed39------2</link>
            <guid isPermaLink="false">https://medium.com/p/e5990e6ef0a</guid>
            <category><![CDATA[accessibility]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[user-interface]]></category>
            <category><![CDATA[design-systems]]></category>
            <category><![CDATA[usability]]></category>
            <dc:creator><![CDATA[Paul Stanton]]></dc:creator>
            <pubDate>Thu, 17 May 2018 07:51:01 GMT</pubDate>
            <atom:updated>2018-05-24T19:43:27.478Z</atom:updated>
            <cc:license>https://creativecommons.org/licenses/by-nc-sa/4.0/</cc:license>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fOjk0lT8lz4_NRhyU7qi2w.png" /></figure><p>In preparation for <a href="http://globalaccessibilityawarenessday.org">Global Accessibility Awareness Day</a>, the Pulsar team has been on an accessibility kick recently, doing various things to improve the accessibility of the <a href="https://github.com/jadu/pulsar">Pulsar design system</a> and the software it serves.</p><p>I took some time to experiment with a handful of popular accessibility testing extensions and tools which we use to validate the accessibility of our user interfaces. These tools will give you a good foundation of accessibility before you move onto user-centric testing with real people and/or full blown accessibility audits. You should consider using these tools to test accessibility much the same way as you test your markup using the W3C validators which has always been one of the most basic tests we all perform before go-live.</p><p><strong>Browser extensions</strong> (I’m using Chrome for the purposes of this post)</p><ul><li><a href="https://wave.webaim.org/extension/">WAVE Web Accessibility Evaluation Tool</a></li><li><a href="https://developers.google.com/web/tools/lighthouse/#devtools">Lighthouse</a></li><li><a href="https://www.deque.com/axe/">aXe browser extension</a></li><li><a href="https://chrome.google.com/webstore/detail/wcag-accessibility-audit/kpfleokokmllclahndmochhenmhncoej?hl=en">WCAG Accessibility Audit Developer UI</a></li><li><a href="https://chrome.google.com/webstore/detail/siteimprove-accessibility/efcfolpjihicnikpmhnmphjhhpiclljc">SiteImprove Accessibility Checker</a></li></ul><p><strong>Other tools</strong></p><ul><li><a href="https://tenon.io">Tenon.io</a> (free and paid plans available)</li></ul><h3>Starting our test</h3><p>I needed a real user interface to test, something fairly small with a handful of form elements and interactions, so I started where all our Continuum users start, our sign-in screen. There’s a small amount of interaction design here, users will move between a few different forms in-place but there’s not an awful lot of markup involved, so for the purposes of this post it’s a good example of how we can work through the various issues flagged by the tools.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vsRLAgRVQ9ujKK90oI3OYw.png" /><figcaption>Our sign-in UI, about to be put through its paces</figcaption></figure><p>First, let’s see what each tool tells us before we make any changes. If the tool gives me the option to filter results I will be setting it to show me anything related to the <a href="https://www.w3.org/TR/WCAG20/">Web Content Accessibility Guidelines 2.0</a> at AA compliance level, although in our real-world testing we’re also interested in looking at <a href="https://www.google.com/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=1&amp;cad=rja&amp;uact=8&amp;ved=0ahUKEwj8k6ONvIfbAhUIW8AKHdz0D48QFggpMAA&amp;url=https%3A%2F%2Fwww.section508.gov%2F&amp;usg=AOvVaw2R6932TGLcQ_68E4Di0ZeM">Section 508</a> compliance for the US market.</p><h4>WAVE Web Accessibility Evaluation Tool</h4><p>This is usually the first browser extension developers think of when accessibility testing comes up, but as I’ll show in the post, it’s probably not the first one you should reach for.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*28upH1HoVbG0R_rTHDwslg.png" /></figure><p>Hitting the WAVE button in Chrome’s extensions toolbar displays the WAVE toolbar as a column inside your window, here it shows me 1 error and 9 alerts. Previously we’ve only focused on resolving ‘errors’ in our internal testing but we’re now increasing our scope to ‘alerts’ also.</p><p>WAVE overlays an icon for each issue on the UI but it gets confused by absolute positioning and doesn’t show any other information about the related element, such as markup or ID/class attributes. This is somewhat problematic if you have issues on UI partials that are not yet visible, such as hidden forms. It takes some hunting around using dev tools to pinpoint the element causing the error. Alternatively, as suggested by Charles Hall in the comments below (Lead developer of WAVE) you can toggle the ‘no styles’ mode which will give you the plain old HTML view of your UI but still show WAVE icons next to the related elements. This also has the handy effect of displaying any UI partials that are visually hidden with CSS.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/813/1*tRT5zFtD9q50w11ZKIzAqg.png" /><figcaption>Inspecting the red icon in the UI leads me to the related element (the `.signin-brand` image, missing an `alt` attribute</figcaption></figure><h4>Lighthouse</h4><p>If you’re running an up-to date version of Chrome, you probably already have Lighthouse because it’s built right in! Open devtools and go to the ‘Audits’ tab, hit the ‘Perform an Audit’ button and you’re given a list of the audits that Lighthouse can perform, we’re only going to run the accessibility audit to save time.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Wzo4KF8ZRRf8g_jrPG2Xvw.png" /></figure><p>Lighthouse is a bit more lenient than WAVE for this sample UI, only complaining about the alt and tabindex issues. It does show affected markup but doesn’t do any highlighting or jumping to the affected elements in devtools. It’s also the slowest test covered here.</p><p>Interestingly, Lighthouse uses axe-core (which we talk about next) for its accessibility audit, but I suspect doesn’t run the full set of <a href="https://github.com/dequelabs/axe-core/blob/develop/doc/rule-descriptions.md">~70 tests</a> that the aXe extension does, I need to look into this a bit more…</p><h4>aXe Browser Extension</h4><p>I’m a big, big fan of aXe, the extension adds a new tab to Chrome’s Dev Tools with a big blue ‘analyze’ button, once you hit that you’re shown a very nice list of issues (I’ve filtered to just show violations here, but there’s also a list of other things to review) with really useful related information.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*G3YNXk3MCewOifXIRXbgbQ.png" /><figcaption>The highlight button does a much better job of showing the element related to the violation</figcaption></figure><p>Each issue show the related markup clearly, hitting ‘inspect node’ jumps right back into the elements tab of DevTools highlighting the element.</p><p>aXe rates the impact of a11y issues differently to WAVE, in this example the alt-text issue is <strong>critical</strong>, the tabindex issue is <strong>serious</strong> and the others are <strong>moderate. </strong>It’s worth noting that this presentation compells me to resolve all of the violations because it tells me there’s nine of them, rather than WAVE telling me there’s one error and nine alerts.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/271/1*B6VnPy92P8ZDLx2xm3iVsg.png" /></figure><p>aXe also lists things for review, which don’t specifically cause a violation of accessibility guidance but may need to be considered based on the actual context of the element within the UI. The galaxy image behind our sign-in UI is actually a video which doesn’t particularly need captions or an audio-description track, but perhaps it needs marking as purely presentational only. I can’t do this yet because we use a third-party library to inject the &lt;video&gt; element, but it’s something for me to review in the future.</p><p>Interestingly, aXe is smart enough to know that the blue box containing our form has opacity (0.9) with an image behind it. The colour contrast issues are flagged because the tool can’t guarantee the background colour would allow the required contrast level of the foreground text to be met (it does, but it’s useful to be reminded to check).</p><h4>WCAG Accessibility Audit Developer UI</h4><p>It only checked four things, and passed them all. In the bin with you.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kxUQFlcxMpwIbNpEso0Cgg.png" /><figcaption>I uninstalled this one.</figcaption></figure><h4>SiteImprove Accessibility Checker</h4><p>SiteImprove is very popular in the waters in which we sail (local &amp; central government, higher education, not-for-profit etc…) so it’s very useful to have a SiteImprove tool to verify the accessibility of our UIs.</p><p>This tool gives a lot of relevant information about issues, though I find the way it’s listed to be a bit more difficult to scan and you need to click into an issue to get the detail specific to that issue, then back out to the main list to see your issues. I do prefer aXe’s master/detail view but SiteImprove does the best it can with the single column constraint.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wR9CAjLyspdxH1667QO6dQ.png" /><figcaption>Very similar results to aXe, although that aria-atomic is a new one! (review issues are filtered out)</figcaption></figure><h4>Tenon.io</h4><p>Tenon is different as it’s a web service you can use much like the <a href="https://validator.w3.org">W3C HTML Validator</a> we all know and love, but for accessibility. Simply give it a link or paste in the markup of your UI and it’ll generate a report for you. There‘s multiple (paid) ways to integrate Tenon with your build tooling or CI servers, but that’s meat for another blog post.</p><p>It’s slower than the in-browser tests, but the main caveat when passing the URL to the browser version is that it needs your site/UI to be publicly available to Tenon. For now I’m just going to use <a href="https://ngrok.com/">ngrok</a> to create a temporary public URL to my localhost, and give that link to Tenon.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*H47Y67eYwA-ipb2F-6kTpQ.png" /><figcaption>Pretty much the same results as the others, nicely presented with markup examples.</figcaption></figure><h4>The scores on the accessible doors?</h4><p>Barring one shambolic effort, all of the tools gave fairly consistent results for this—admittedly limited—UI test. For me to give them some form of ranking it came down to how the information is presented and what tools it gives me to resolve the issues it raises. Realistically there’s no silver bullet and we’ll likely use most if not all of these tools to sanity check each UI, but the first tool I use in nearly all cases is the aXe browser extension in Chrome. The information is clear, well organised and the highlighting and dev tools integration make it the best tool out of the ones I’ve tested so far. I’m also very interested in integrating aXe core or Tenon.io into our CI process in the near future, for more automated on-going testing.</p><p>So in terms of results, my personal order of usefulness is:</p><ol><li>aXe</li><li>SiteImprove</li><li>Tenon</li><li>WAVE</li><li>Lighthouse*</li></ol><p><em>*I wouldn’t write-off Lighthouse as irrelevant, as long as Google keep updating the number of audits it will continue to improve.</em></p><h3>The fixes</h3><p>So I know I have things to fix, and to be honest I’m not going to bore you with those, I’m only going to use aXe during my initial pass and then see what the other tools tell me.</p><p>The fixes, in brief, involved:</p><ul><li>Adding alt-text to the ‘Continuum’ brandmark image</li><li>Add &lt;main&gt; wrapper around the content to act as an aria-landmark region</li><li>Change the ‘Pulsar’ text into a h1 heading (with CSS fixes to maintain size)</li><li>Remove a bit of javascript which added incrementing tabindex values (1, 2, 3 etc) in favour of simply 0 or -1</li><li>Added id attributes to the ‘forgot password’ and ‘sign in’ forms to act as the target for the related skip-links</li></ul><p>After those fixes, let’s take them for another spin in the testing tools.</p><h4>aXe = No violations 🎉</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iokoqS-wf2zRcTOkDOjRXg.png" /></figure><h4>WAVE = no errors, no alerts 🎉</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*g7u_SBil-065O0QDDXakHg.png" /></figure><h4>Lighthouse = no errors 🎉</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QadGtLUdVKOTiZ36KUr2KQ.png" /></figure><h4>SiteImprove 💥</h4><p>OK, so SiteImprove still isn’t happy…</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*z6dmU18P0CDT1C8Ky6B0iQ.png" /></figure><p>First, let’s drill into the issue with contrast, earlier using aXe we saw how it couldn’t figure out the colour of our background because of the opacity of the container, but that’s not what SiteImprove is complaining about…</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uVTwjLAC-aZ54kFsKXTCLw.png" /></figure><p>SiteImprove thinks that the background of all these elements is white, in all honesty I’m not sure why but my first thought was that perhaps it’s ignoring the video and the fallback image isn’t loading, but the background colour on the underlying body element is, of course, white. So setting an explicit colour for the container underneath the video keeps SiteImprove happy in this instance, and catches any situations where both the video and fallback image fail to load while keeping the white text visible. A worthwhile fix.</p><p>Next up, bypass blocks.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mgXS20EVPZPZcfF5ltQIRg.png" /></figure><p>SiteImprove wants me to put a top-level skip-to-content link in which we could do with across our entire UI, so that’s an easy one to check off.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/397/1*5xYH__UG9miA4aBW9Ai2fw.png" /><figcaption>The ‘Enter your username and password’ alert is an element with role=”alert”</figcaption></figure><p>Lastly, that aria-atomic thing, we use a aria-live region using role=&quot;alert&quot; (the ‘Pulsar’ text) to change to display warnings or errors as the user is attempting to sign in, any change to the content here is announced by screenreaders.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Ehimr8Hdw9Vv9QruAc591w.png" /></figure><p>Adding aria-atomic=&quot;true&quot; makes sure the screenreader announces the whole region if part of it changes, we don’t actually need it in this case but SiteImprove doesn’t know we’ll always update the whole region, so it’s good to reassure the tool that it’s going to happen and to guarantee the behaviour in screenreaders.</p><p>So a few more quick tweaks and we’re done! SiteImprove is happy!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fwZEY1K-zEGlUnt6nkb_nw.png" /></figure><h4>Tenon.io 💥</h4><p>Lastly, a few more nitpicky bits from Tenon…</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WIEu4NX8dtej8Wcmfc-OiQ.png" /></figure><p>The first two are in relation to field labels not being unique. Both our sign-in and forgotten password forms ask for a username and Tenon gives us the correct advice about wrapping them in a fieldset, however after doing so it still flags this as an <strong>error</strong> at the time of writing. I believe this is a bug and have fed this back to Tenon support.</p><p><strong><em>*Update* Since publishing, Tenon have confirmed this is a bug and will fix it in an upcoming release.</em></strong></p><p>The other last one is complaining about a href=&quot;#&quot; in some example code for this UI, Tenon complains loudly about absolutely every instance of using a hash symbol as a href so if you’re wanting to test prototype, sample or demo code you’ll find yourself mopping these up all over the place.If you’re using &lt;a href=&quot;#&quot;&gt;something like this&lt;/a&gt; as a trigger for javascript behaviour you should consider using a &lt;button&gt; instead, or if it absolutely has to be a link then maybe you need an actual link as a fallback for when js doesn’t load instead of an empty hash. There’s normally never an actual time for you to use href=&quot;#&quot; in production code, so it’s good that Tenon catches this.</p><h3>Findings</h3><p>After experimenting with this range of browser based accessibility testing tools, the most important thing to take away is that no one tool gave me a complete list of issues found by the others, <strong>you really do have to test in multiple tools</strong>.</p><p>I’ve pretty much adopted the aXe browser extension as my primary testing tool, once I’ve resolved any issues there I move onto SiteImprove, Tenon.io and then WAVE. This allows me to clear up a great deal of accessibility issues in our user interfaces and clears the decks for us to perform device testing with assistive technologies such as screen readers. More on that soon.</p><p>And once more, for those skimming to the end of the article to find the answer sheet, my personal order of usefulness is:</p><ol><li>aXe</li><li>SiteImprove</li><li>Tenon</li><li>WAVE</li><li>Lighthouse</li></ol><p>If there’s any other tools or methods you use to good effect, please do let me know!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e5990e6ef0a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pulsar/which-accessibility-testing-tool-should-you-use-e5990e6ef0a">Which accessibility testing tool should you use?</a> was originally published in <a href="https://medium.com/pulsar">Pulsar</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Making form inputs more obvious by removing padding]]></title>
            <link>https://medium.com/pulsar/making-form-inputs-more-obvious-by-removing-padding-e1845528288e?source=rss-5d2d5205ed39------2</link>
            <guid isPermaLink="false">https://medium.com/p/e1845528288e</guid>
            <category><![CDATA[web-design]]></category>
            <category><![CDATA[design-systems]]></category>
            <category><![CDATA[css]]></category>
            <category><![CDATA[design-patterns]]></category>
            <category><![CDATA[web-development]]></category>
            <dc:creator><![CDATA[Paul Stanton]]></dc:creator>
            <pubDate>Thu, 02 Nov 2017 10:10:16 GMT</pubDate>
            <atom:updated>2017-11-02T10:17:52.648Z</atom:updated>
            <cc:license>http://creativecommons.org/publicdomain/zero/1.0/</cc:license>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pKbhC9xICAdBwye0ARhPsw.png" /></figure><p>I recently did a chunk of work on the <a href="http://github.com/jadu/pulsar">Pulsar design system</a> to improve how we align form elements against a common 12 column grid, and all sorts of fun little things crept out of the woodwork that we’re still tweaking.Normally, when you’re styling up your forms you’d add padding to both the left and right sides, right? It’s pretty much standard practice everywhere.</p><p>Previously, we used specific pixel values to set the widths of our inputs which—while great from a consistency point of view—was awful in terms of responsiveness. We worked out a responsive 12 column grid, three of which would be our main form labels, and the remaining 9 made available to form inputs, with the default being set to 4 columns wide.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1M4XjNu3E2bU2FqgzzrXIg.png" /><figcaption>A form input can be 1–9 columns wide</figcaption></figure><p>When we used pixel widths, our inputs were designed with internal padding on both the left and right edges, which was fine when we could rely on a developer choosing the most appropriate width class, like .form__group--small to suit their expected input widths.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/501/1*hlrTbchr3GEjE_1Uu94ebQ.png" /><figcaption>The behaviour before, when we knew exactly how wide a given input would be</figcaption></figure><p>However, that padding caused us a problem when we allowed form inputs to be completely responsive, growing and shrinking based on the widths of the responsive columns, depending on the width of the value there’s a chance that when the text overflows, the right hand padding hides the fact that the value is overflowing.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/319/1*UPHgEpe0DnA3yMc-yak23Q.png" /><figcaption>At certain widths, our 600 looks like 6</figcaption></figure><p>Luckily, we’re able to fix this easily by removing the right hand padding, allowing the value to extend right to the edge of the input. If, at some point, we add RTL language support to our software then we’ll need to remove the left instead.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/320/1*R-oeUy4CDB8Gc1j_SmyM_A.png" /><figcaption>It’s not as pretty, but it’s obvious that the value is larger than 6</figcaption></figure><p>It’s not as visually pleasing, but it makes it much more obvious that the value extends beyond the visual container and does as much as we can to remove ambiguity and the opportunity for error.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e1845528288e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pulsar/making-form-inputs-more-obvious-by-removing-padding-e1845528288e">Making form inputs more obvious by removing padding</a> was originally published in <a href="https://medium.com/pulsar">Pulsar</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Testing for unforseen visual change]]></title>
            <link>https://medium.com/pulsar/testing-for-unforseen-visual-change-dca842037e5f?source=rss-5d2d5205ed39------2</link>
            <guid isPermaLink="false">https://medium.com/p/dca842037e5f</guid>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[user-experience]]></category>
            <category><![CDATA[testing]]></category>
            <category><![CDATA[css]]></category>
            <category><![CDATA[style-guides]]></category>
            <dc:creator><![CDATA[Paul Stanton]]></dc:creator>
            <pubDate>Fri, 21 Oct 2016 08:27:19 GMT</pubDate>
            <atom:updated>2017-02-15T19:26:33.654Z</atom:updated>
            <content:encoded><![CDATA[<h4>Your computer can (probably) see better than you</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Lo4VJQiU35domME4QMtIAg.jpeg" /></figure><p><em>In </em><a href="https://medium.com/pulsar/testing-our-design-system-components-45aa0eab99fd#.1r6gsv6hl"><em>part 1</em></a><em> I explained how we use unit tests to validate that the markup generated by our design system components matches our expectations from one release to the next. In this part, I’ll show how we check the visual presentation of those same components.</em></p><h3>We start again, with a button.</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/1*kchASbcEqOAyINQzIkg7tQ.png" /><figcaption>Remember me?</figcaption></figure><p>Our humble button has 8 possible main colour variations, things like btn--primary, btn--success, btn--danger, etc. It can also have a number of other modifiers, like btn--outline, btn--small, btn--naked or is-disabled and it could have one, multiple or all of them at any one time. Oh, and don’t forget active, hover and focus, yeah?</p><p>You want a small, primary, disabled, outline button? We got you.</p><p>Certain classes need to take priority over others, regardless of the order in which they’re applied by the developer coding the UI. That’s a lot of variations to check, and a bit of a cascade jigsaw puzzle to code up; we’re pretty protective of the colour combinations for the default states because they all meet the <a href="https://www.w3.org/TR/UNDERSTANDING-WCAG20/visual-audio-contrast-contrast.html">WCAG 2.0 AA standard for colour contrast</a>, Something which we aim for in all our user interfaces.</p><p>So if you use…</p><pre>btn btn--primary btn--outline btn--small btn--disabled</pre><p>…it should result in the same visual styling as…</p><pre>btn btn--disabled btn--outline btn--small btn--primary</pre><p>To test this I’ve set up grids of buttons, mapping out the various combinations of classes so we can visually scan through them while also checking their interactive states.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*j3I7x0KZO-dYQQxGRkAjVA.png" /><figcaption>Just one of many button grids</figcaption></figure><p>I have a page full of button combinations, 384 of them in fact. So many, that it’s unrealistic to expect anyone to <a href="https://media.giphy.com/media/AZemObXVMo4mY/giphy.gif">visually check these</a> for each release to make sure nothing has changed. So it’s time to employ one of my guilty pleasures—Visual Regression Testing 🙌</p><p>Remember those Twig fixture files we previously used with PHPUnit? I use the <a href="http://bbc-news.github.io/wraith/">BBC’s Wraith tool</a> to take screenshots of each and every one. Wraith uses a headless version of WebKit and stores those images as a visual baseline—a defined and verified standard that we want future screenshots to match; Unless we’re making explicit changes, of course.</p><p>Every time we make changes to a stylesheet we can re-run Wraith which will take a second set of snapshots, then automatically compare them against each other and report any differences, no matter how small.</p><p>This means that if one of our 384 buttons suddenly got a different label colour than we were expecting, Wraith will tell us. If one of the buttons suddenly became wider by 1 pixel, Wraith will tell us.</p><blockquote>Wraith is that annoying colleague who hovers over your shoulder and points out the tiniest difference, but only when you ask it to, which is nice.</blockquote><h3>Shall we play a game?</h3><p>Here’s two screenshots of that button grid but I’ve made a change, can you see it? <strong>Try not to scroll down too much</strong> until you’ve had a good look…</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xZqPHR8I5w_WbzkaRsW8Kw.png" /><figcaption>Stop scrolling, can you tell what it is yet?</figcaption></figure><h3>Figured it out yet?</h3><p>I can’t tell, but Wraith can.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*x9sWH3sVlhByPM5TO4eL0A.png" /><figcaption>Wraith: “What the f… m8??”</figcaption></figure><p>I lightened the label colour for the naked buttons by <strong>1%</strong>, too small a difference to be detected by my eyes, but more than enough for a computer to notice. Admittedly, I had to dial Wraith’s tolerance all the way down to zero to get it to pick up this small of a difference (you can tell it to work with a certain percentage ‘fuzz’ factor) but I wanted to make a point ;)</p><p>At the end of the process we’re informed about any failures, although failures is a strong word as they’re just “differences”, it’s down to us to decide whether those differences are intended or not. We’re even given a handy HTML gallery of all the screenshots to easily work through and visually check whatever it’s found.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Q-_rns00OsbIbSvePmd8bQ.png" /><figcaption>Gallery of Fails</figcaption></figure><h3>Spend time setting up a safety net</h3><p>If you work on a design system, however large, spending time learning and setting up a tool like Wraith will reduce the amount of time you spend manually checking your components every time you make a change, and it’ll let you release with more confidence that unintended changes haven’t leaked out to other components.</p><blockquote>No-one likes leaky styles</blockquote><p>We don’t use visual regression testing to fail builds, but it’s becoming an extremely valuable safety net to run before committing changes or performing a release of our design system. We’ve all had issues where a change with CSS is one place affects other components in ways we weren’t expecting, and Wraith helps us catch those.</p><p>There’s an investment to be made in setting up the tests. We were lucky enough to be able to tap into the hundreds of helper tests we already had and make them work in Wraith too, and we’re now adding tests cases (like the button grids) purely for the visual regression testing.</p><p>Finally, the biggest benefit I’ve found is during refactoring. I’m much more confident in making larger-scale changes because I can run my visual tests and have Wraith check all of my components for me.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=dca842037e5f" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pulsar/testing-for-unforseen-visual-change-dca842037e5f">Testing for unforseen visual change</a> was originally published in <a href="https://medium.com/pulsar">Pulsar</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Testing our design system components]]></title>
            <link>https://medium.com/pulsar/testing-our-design-system-components-45aa0eab99fd?source=rss-5d2d5205ed39------2</link>
            <guid isPermaLink="false">https://medium.com/p/45aa0eab99fd</guid>
            <category><![CDATA[unit-testing]]></category>
            <category><![CDATA[style-guides]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[front-end-development]]></category>
            <category><![CDATA[design-systems]]></category>
            <dc:creator><![CDATA[Paul Stanton]]></dc:creator>
            <pubDate>Tue, 18 Oct 2016 10:12:24 GMT</pubDate>
            <atom:updated>2016-10-26T07:21:30.284Z</atom:updated>
            <content:encoded><![CDATA[<h4>Avoiding the unforseen consequences of change</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8TlCiGBdPWLM3tP4o93nag.jpeg" /><figcaption>“I never thought I’d see a resonance cascade, let alone <br>create one.”</figcaption></figure><p>We have lots of components in our <a href="https://github.com/jadu/pulsar">Pulsar design system</a>, but for this post I’m going to focus on just one. The button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/67/1*AG5qo9S88_io7zkQlU1YbA.png" /><figcaption>A button, you click/tap it, something happens (usually).</figcaption></figure><p>Buttons are prolific in our software, they do lots of different things and they need to be consistent, recognisable and predictable. Our buttons can have a handful of classes applied which define the colour (primary, success, danger etc), visual variations (small, outlined, naked) and the state (disabled, active) as well as the normal set of interactive states that a button needs to support (hover, active, focus).</p><p>We test lots of things about our humble little button, like:</p><ul><li>Is the markup generated by the button helper correct?</li><li>Does the CSS render the button variations correctly?</li><li>Do all of the colour combinations match what we expect?</li><li>Has anything else changed that we weren’t expecting?</li></ul><h3>Part 1: Testing the markup</h3><p>We use the <a href="http://twig.sensiolabs.org">Twig</a> templating language which gives us a lot of features to play with but the main one we take advantage of are <a href="http://twig.sensiolabs.org/doc/tags/macro.html">macros</a>, although we call them ‘helpers’ within Pulsar.</p><p>Helpers let us provide, for want of a better description, an API for the UI. Instead of using the raw HTML markup for a button in a view, we can call the button helper with a set of options, and the relevant markup will be created for us when the page is viewed in-browser.</p><p>This helper:</p><pre>{{<br>    html.button({<br>        &#39;label&#39;: &#39;Foo&#39;,<br>        &#39;class&#39;: &#39;btn--primary&#39;<br>    })<br>}}</pre><p>will spit out the following HTML:</p><pre>&lt;button class=&quot;btn btn--primary&quot;&gt;Foo&lt;/button&gt;</pre><p><em>I know you’re probably wondering “why is this any better than normal markup” and admittedly, a button is probably the least impressive example I can give (form elements have a good amount of wrapper markup), but we’ll keep it simple with buttons for now.</em></p><p>There’s a few <a href="https://jadu.gitbooks.io/pulsar/content/button.html">documented options</a> that a button may have. Supply &#39;type&#39;: &#39;link&#39; and you’ll get &lt;a href=&quot;#&quot; class=&quot;btn btn--primary&quot;&gt;Foo&lt;/a&gt; instead of &lt;button&gt;, as well as different markup for input and submit types too. We need to test all of those to make sure the markup created by our helper is correct, valid and that any other supported options like disabled are added as correctly formatted attributes.</p><p>We have a suite of fixtures, which consist of a .twig file (the input) and a matching .html file containing the expected output. The Twig fixtures all run through PHPUnit and their output is matched against the ‘expected’ HTML file. The Pulsar repository has hundreds of fixtures being tested in this way, everything from buttons to more complex components like the primary navigation module.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qCKFnYTx0dDT5xRmA67L6w.png" /><figcaption>Happy days! Helpers are rending as expected in Twig PHP</figcaption></figure><p>As an example, if I intentionally add a newClass class to the helper and run PHPUnit again it will fail any fixtures that weren’t expecting a button with newClass. If the change is expected, I can verify which components are depending on the button helper and may be affected by the change or, if the change to the helper wasn’t expected, I can fix that instead!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/746/1*cHhpuXHgGLqI07TSa0BTgQ.png" /><figcaption>F.F.F.F.F.F.F.F.Failures!</figcaption></figure><p>Taking the time to write unit tests for our helper markup helps massively when it comes to refactoring and bug fixing, we can quickly run the test suite to confirm that our changes within Twig have not affected the markup in ways we weren’t expecting.</p><p>But wait, there’s more!</p><p>Twig is a PHP templating language but there’s also the <a href="https://github.com/twigjs/twig.js">Twig.js</a> javascript implementation. We want Pulsar to be usable in Node projects so we run the exact same set of PHPUnit fixtures through Twig.js to make sure the markup is still fine (when we first did this, the markup was wildly different, but thanks to a couple of PRs being accepted into the twig.js project, it’s fine now).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/720/1*dpUSDDtRlMSj8QhArP082A.gif" /><figcaption>Woo! Look at it fly!</figcaption></figure><h3>What next?</h3><p>So we have this comprehensive fixture suite pulling double-duty, testing our generated markup is correct in both the PHP and JS implementations of Twig. In my next post I’ll show how we use the same fixtures again to test the visual output and let us know if anything changed, right down to the pixel.</p><p><em>Header image from </em><a href="https://www.blackmesasource.com"><em>Black Mesa</em></a><em>, used under fair use.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=45aa0eab99fd" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pulsar/testing-our-design-system-components-45aa0eab99fd">Testing our design system components</a> was originally published in <a href="https://medium.com/pulsar">Pulsar</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Retiring pieces of a design system]]></title>
            <link>https://medium.com/pulsar/retiring-pieces-of-a-design-system-d5ebb080d755?source=rss-5d2d5205ed39------2</link>
            <guid isPermaLink="false">https://medium.com/p/d5ebb080d755</guid>
            <category><![CDATA[css]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[design-systems]]></category>
            <category><![CDATA[style-guides]]></category>
            <category><![CDATA[sass]]></category>
            <dc:creator><![CDATA[Paul Stanton]]></dc:creator>
            <pubDate>Thu, 13 Oct 2016 13:58:40 GMT</pubDate>
            <atom:updated>2016-10-26T07:22:43.150Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4V71_iwx6RG0see7xmEUXA.jpeg" /></figure><blockquote>“Don’t break the build.”</blockquote><p>The mantra you’ll hear often if you work with a continuously integrated product. Design systems, frameworks, pattern libraries or whatever we’re calling them this week usually live outside of the product(s) in which they’re used. They’re products in and of themselves, with their own team, their own backlog and their own release cycles. Updating to the latest version of your design system should rarely, if ever, intentionally break something which you previously supported.</p><p>Hell hath no fury like a developer who’s build breaks with a minor patch release of a dependency. Similarly, you’ll suffer scorn if you’re constantly releasing major versions because of the amount of breaking changes you’re publishing. The Pulsar design system got to version 6.x.x pretty quickly when we first started integrating it with our existing software products, but has stayed stable there for quite a while now because we’re increasingly focused on not breaking things. Which is generally a good thing for everyone.</p><p>Now, that’s not to say we don’t refactor things, or even remove things altogether, we do it all the time! We just take a few steps to make sure that the changes we make are as minimally disruptive as possible. The following process we use for retiring components may come in handy for you.</p><h3>Retiring components</h3><p>If you’re like us, you’ll have a lot of components with their related Sass files, every now and then we’ll go through ours and check they’re all still being used. After all, software features get retired and things get rewritten into newer and better alternatives so sometimes we need to just get rid of older components from the system.</p><p>Pulsar has a main Sass file pulsar.scss which imports all of the individual components but this is a reference file and not used in production. Each Continuum product has its own version of this file only importing the specific components they require, as well as adding any product-specific code they may need which aren’t appropriate to keep in Pulsar.</p><p>Say we want to remove a component no-one wants anymore, let’s call it _component.millhouse.scss, simply removing this file from the Pulsar repository would break the build of Continuum products attempting to import it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0TeHgIiPqUdUvTe1c8FLWw.png" /><figcaption>🗑→ 🙈</figcaption></figure><p>!optional imports still aren’t a thing in Sass, unfortunately, so we take a few steps to gradually phase Millhouse out over a few releases.</p><h4>1. Move the contents of _component.millhouse.scss into _deprecated.styles.scss</h4><p>All Continuum products include this deprecated styles file, we include docblock-style comments to explain where they came from, why they’re being deprecated and the date which they were moved. This is useful for the later step of cleaning out the unwanted styles when we’re confident they’re no longer referenced in production.</p><pre>/* -------------------------------------------------------------- *\</pre><pre>04/07/2016 - Paul Stanton</pre><pre>_component.millhouse.scss</pre><pre>Millhouse component replaced by Nelson component.</pre><pre>\* -------------------------------------------------------------- */</pre><pre>.millhouse { ... }</pre><p>At this point we’ve not broken the build, but our final CSS output still contains the .millhouse classes, we need to warn people that they’re being phased out.</p><h4>2. Communicate the change</h4><p>We publish <a href="https://jadu.gitbooks.io/pulsar/content/">release notes</a> with each Pulsar version listing new features, bug fixes etc, and if we’re planning on removing something we mention it here too. But not everyone reads your meticulously crafted release notes so you can never guarantee someone will notice your warning.</p><p>Remember that empty _component.millhouse.scss file? Time to put it to use.</p><p>Sass has a handy <a href="http://sass-lang.com/documentation/file.SASS_REFERENCE.html#_6">@warn</a> feature that lets you throw warning messages during compilation, we add a warning message inside this file informing product teams that the component is being phased out, and that this Sass file should be removed from their imports.</p><pre>@warn &#39;_component.millhouse.scss has been deprecated and needs to be removed from your main pulsar.scss file. UAT teams should not treat this as a build failure. (Stanton, 04/07/2016)&#39;</pre><p>If you’re lucky enough to have dedicated test engineers, you’ll know that their finely tuned spidey-sense tingles whenever they sense a disturbance in the build, even though @warn will not trigger a build failure, it’s enough of an error to make them rightfully err on the side of caution and possibly fail a ticket. We include a message asking for it to not be treated as a build failure, but something that should still be followed up. Again, we put our name and date on the warning which helps the teams know who’s responsible for the warning and give them the chance to ping them on Slack, for example.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*o2vXnP0jNIC3bQYpsWNKYA.png" /><figcaption>The result of the @warn message in terminal</figcaption></figure><h4>3. Remove the @import from the product</h4><p>Each product team at Jadu has a Pulsar team member working within it, it’s usually us that will create a ticket and pull request to remove the reference to _component.millhouse.scss from the product’s mainpulsar.scss file. This then goes through the usual process of peer review and testing.</p><h4>4. Remove the .millhouse code from _deprecated.styles.scss</h4><p>After a while it should be safe to remove the .millhouse styles, normally we’d search the codebase for any remaining references of it in the products before we do, again, trying not to break the build, and typically we’d do this at the start of a sprint so that any unforseen regressions would hopefully surface during the course of regular work and testing.</p><p>We do <a href="https://jadu.gitbooks.io/pulsar/content/visual-regressions.html">visual regression testing</a> on changes like this too, which helps to identify any unexpected consequences.</p><h4>5. 🎉</h4><p>Job done!</p><p>We’ve done this a few times in Pulsar to allow us to gradually and safely remove older code that may still be referenced in production, without the need to resort to releasing a new major version each time. If you have any better suggestions, we’d love to hear them!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d5ebb080d755" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pulsar/retiring-pieces-of-a-design-system-d5ebb080d755">Retiring pieces of a design system</a> was originally published in <a href="https://medium.com/pulsar">Pulsar</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Pulsar — The design system for Jadu]]></title>
            <link>https://medium.com/pulsar/pulsar-the-design-system-for-jadu-6ce0031fa28a?source=rss-5d2d5205ed39------2</link>
            <guid isPermaLink="false">https://medium.com/p/6ce0031fa28a</guid>
            <category><![CDATA[design-systems]]></category>
            <category><![CDATA[style-guides]]></category>
            <category><![CDATA[ux]]></category>
            <category><![CDATA[design]]></category>
            <category><![CDATA[jadu]]></category>
            <dc:creator><![CDATA[Paul Stanton]]></dc:creator>
            <pubDate>Wed, 12 Oct 2016 13:17:07 GMT</pubDate>
            <atom:updated>2017-02-13T11:13:06.769Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lh6KECdCyC43-yytK7z4iw.jpeg" /></figure><p>Pulsar is the open-source design system powering the user experience of the Jadu Continuum platform. Sounds fancy, but what does it really mean?</p><p>Jadu software is used in large organisations, it powers hundreds of local government/council sites as well as some in central government, higher education and commercial sectors. There are thousands of people who use our software every day to deliver sites and services used by millions.</p><p>The Jadu Continuum Platform currently consists of the following main products:</p><ul><li><strong>CMS</strong> — Content Management System</li><li><strong>CXM </strong>— SAAS based Customer Experience Management</li><li><strong>XForms Professional</strong> — Secure Forms</li></ul><p>Customers may have one, two or all the Continuum products, and some of their users may access one or more of them as part of their job. It’s important to us that each product maintains a consistent, familiar experience even though their main features may differ. Simply put, you should be able to jump into a different product and know your way around.</p><p>Each product has a dedicated team of developers and testers, and each team has a Pulsar team member responsible for designing the user interfaces for new features as well as looking after the design and experience of their team’s product as a whole.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FrmGUTvuBvdw%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DrmGUTvuBvdw&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FrmGUTvuBvdw%2Fhqdefault.jpg&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=youtube" width="640" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/c7a8bb7b38631e9413591f80d62750e7/href">https://medium.com/media/c7a8bb7b38631e9413591f80d62750e7/href</a></iframe><p>We developed the Pulsar design system to provide a single framework that all products use to deliver consistent, stable and well designed experiences. Jadu engineers have well documented methods to create everything from a single button up to more complex components all coming together to make full user interfaces.</p><p>We design in the open as much as possible, publishing screenshots and wireframes on a <a href="https://trello.com/b/xGy7NfoA/continuum-ui-roadmap">Trello board</a> with a rough idea of their progress from conception to delivery, we have <a href="https://jadu.gitbooks.io/pulsar/content/">public documentation</a> and of course, all our code is <a href="https://github.com/jadu/pulsar">on GitHub</a> under the MIT license.</p><iframe src="https://cdn.embedly.com/widgets/media.html?type=text%2Fhtml&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;schema=instagram&amp;url=https%3A//www.instagram.com/p/BD6UHBNPFky/&amp;image=https%3A//i.embed.ly/1/image%3Furl%3Dhttps%253A%252F%252Fscontent.cdninstagram.com%252Ft51.2885-15%252Fs640x640%252Fsh0.08%252Fe35%252F12918538_922132011218783_1503345770_n.jpg%253Fig_cache_key%253DMTIyMzM3ODY5MjA0Njg3MDgzNA%25253D%25253D.2%26key%3D4fce0568f2ce49e8b54624ef71a8a5bd" width="640" height="640" frameborder="0" scrolling="no"><a href="https://medium.com/media/4a033ef809572f2e519e32b941a74ba1/href">https://medium.com/media/4a033ef809572f2e519e32b941a74ba1/href</a></iframe><p>All of this is to engage more with our customers as a design team, giving them the opportunity to get involved in the early stages so that we can learn any particular requirements that we may not have thought of.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pBRXsF-2qJdQG4HepeoMeg.png" /><figcaption>The <a href="https://trello.com/b/xGy7NfoA/continuum-ui-roadmap">Continuum UI roadmap Trello board</a></figcaption></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6ce0031fa28a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pulsar/pulsar-the-design-system-for-jadu-6ce0031fa28a">Pulsar — The design system for Jadu</a> was originally published in <a href="https://medium.com/pulsar">Pulsar</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My right-brain burnout]]></title>
            <link>https://medium.com/@coffeepowered/my-right-brain-burnout-60bf07f0a01a?source=rss-5d2d5205ed39------2</link>
            <guid isPermaLink="false">https://medium.com/p/60bf07f0a01a</guid>
            <category><![CDATA[burnout]]></category>
            <category><![CDATA[productivity]]></category>
            <category><![CDATA[life]]></category>
            <dc:creator><![CDATA[Paul Stanton]]></dc:creator>
            <pubDate>Tue, 11 Oct 2016 09:18:06 GMT</pubDate>
            <atom:updated>2016-10-11T09:18:06.238Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JEcveohE4zGpa4cd-GgTfQ.jpeg" /></figure><p>It happens every year, almost always at the same time. Autumn kicks in, the weather starts getting cooler, and my mood swings upwards so much that I never fail to notice how much happier I’ve suddenly become and start commenting on how Autumn is my favourite time of year.</p><p>It’s only recently that I’ve realised this upswing for what it really is: Recovering from burnout.</p><p>I don’t know if its a seasonal affective thing each summer or just coincidence but I definitely feel the change when its over, I just don’t really realise it at the time.</p><p>When I think about the effect that burnout has on me it always seems to be my right brain that’s affected more, my desire to create, design and make awesome things takes a back seat for a while. Its not that my creative output entirely vanishes, I still need to function as part of a creative team, but I do feel less of a desire to do certain things, especially outside of work.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*d-fuTwEiUptt2tu1Ov1Nqw.png" /><figcaption>I know GitHub’s little green squares aren’t a reliable indicator of productivity and the signs are subtle, but they’re there if you squint hard enough</figcaption></figure><p>Fortunately enough, I still have my left-brain pick up the slack and keep me productive (and employed). I instinctively swing into the more of the technical side of my job for a while; writing more code, tests, documentation or looking at things like our build process with a renewed intensity. Over the past few weeks I had a whale of a time implementing visual regression testing on our <a href="http://github.com/jadu/pulsar">design system</a>, something that I wouldn’t have had much interest in looking at if my creative brain was taking the lead.</p><p>I’ve been thinking about what I could do to plan around this for the next time. Perhaps while my internal pendulum is over in my right-brain I need to stockpile my creative output ready for the swing into my left-brain, when I’ll have the technical mindset to develop and implement the backlog of things I’ve got ready to build out.</p><p>Hopefully I can figure out a way to prevent creative burnout from affecting me for so long, whether that’s making time each week for purely creative ventures when I’m in left-brain mode, and vice-versa, by forcing myself to do technical tasks when I’m in right-brain mode. The first step is understanding, now it’s time to find some form of healthy balance.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=60bf07f0a01a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Polishing the pulsar]]></title>
            <link>https://medium.com/pulsar/polishing-the-pulsar-f2c336dfb5d8?source=rss-5d2d5205ed39------2</link>
            <guid isPermaLink="false">https://medium.com/p/f2c336dfb5d8</guid>
            <dc:creator><![CDATA[Paul Stanton]]></dc:creator>
            <pubDate>Tue, 17 Feb 2015 14:47:56 GMT</pubDate>
            <atom:updated>2015-02-18T10:32:19.587Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*C7NQ-Cr7eLCL45Mcono7sQ.gif" /></figure><p>Let me tell you something, pendejo, by the time you’re reading this Pulsar version <strong>3.0.0</strong> should’ve been tagged and released and it was very cathartic. After using Pulsar in anger on the <a href="http://jadu.net/moj">MoJ</a> and <a href="http://jadu.net/q">Q</a> projects for the best part of two years we learnt a hell of a lot about what it takes to write a UI framework that needs to work across multiple products and now I’m taking the time to fix and polish up a lot of things before we start to FINALLY bring Pulsar into <a href="http://jadu.net/content-management-system">Jadu CMS</a>.</p><p>Originally, this blog was only ever meant to be available internally at Jadu, so there’s a lot of inside baseball here and I apologise. In the future I hope to write more about our process, how we’re building our user interface platform and how we’re changing everything to make sure our software is beautiful to use, as well as great to look at.</p><p>Originally, the idea for the Pulsar UI framework was there would be a nicely compiled package that would be either hosted or distributed and that a Jadu product like CMS or Q would simply include this package, then add its own stuff on top. This turned out to be rather naive and fell apart as soon as we started thinking about theming Pulsar for the TPT Portal. If Pulsar was only distributed as a ‘built’ package, anything we’d have to do to theme the default styles would have to be overly specific to override the default selectors. Even something as simple as changing the font stack would have to be written as an override.</p><p>Now each product is responsible for compiling the Sass and has the opportunity to insert their own theme files into the build and override any base variables (all Pulsar vars now use !default) or to add completely custom Sass that doesn’t necessarily belong in Pulsar core, which is intended to be common across all Jadu products.</p><p>I plan on writing a bit more information about how Q extends Pulsar with its own custom components and how it all gets pulled in and built with the magic of Composer and Grunt, but that’s a post for another day. I also want to share more about what’s going on in Pulsar and the work we’re doing to improve the experience of our software for our users as well as improving how we communicate what’s changed for those of you already using Pulsar, so expect some nice changelogs coming your way soon.</p><p>So to catch up, some recent highlights (not just limited to 3.0.0) include:</p><ul><li><strong>New</strong> html.panel component</li><li><strong>New</strong> html.label_group component</li><li>Rewrote all helpers to remove the need for named arguments, now everyone gets along nicely</li><li>Made all helpers compatible with Twig’s strict_variables mode</li><li>Added an AttributesParser Twig extension to simplify how html element attributes are passed around inside macros</li><li>Added new excludes() and only() array filters for Twig, now you can be a bit more bossy about what your arrays do</li><li>Switched to the official <a href="https://github.com/twigphp/Twig">twigphp/twig</a> repository instead of jadu/twig which was a fork of fabpot/twig (did you follow all that?)</li><li>Went through the 12 step programme and removed the Bourbon dependency from Sass</li><li>Remixed the state colours (success, error etc) to meet WCAG 2.0 AA guidelines for contrast ratios, you can now read the text, which is nice</li><li>Made buttons look pretty (buttons used to use Bourbon’s button styling, eww)</li><li>Updated popover styling to make them a bit sharper and standouty (totally a word)</li><li>Added Vagrant hawtness for running the Pulsar development environment in a VM like the cool kids</li><li>Did a blog</li></ul><h3>Macro Madness</h3><p>This is a biggy, and worth talking a little about. Since we first decided to use Twig as our templating language there was a <a href="https://github.com/twigphp/Twig/issues/1157">known issue</a> with using named arguments in inherited templates, I was able to ‘bodge’ a fix which, although it fixed our specific needs, didn’t address the underlying cause within Twig, the fix for this seems to have been pushed for the Twig 2.0 release so we couldn’t wait any longer, things had to change.</p><p>So over the past couple of weeks I’ve been rewriting all helper macros, which was a bit of a grind but absolutely necessary to remove that technical debt before we start plugging Pulsar into the CMS in the coming weeks. While I was in there I generally tidied, DRYed and polished things up, wrote a load of documentation and added the ability for almost every macro to support common options like Classes, IDs and data attributes which was only done on an as-required basis previously.</p><p>The macro syntax has changed too and arguments are now passed through a hash.</p><pre>html.button({</pre><pre>    ‘class’: ‘btn—-primary’,</pre><pre>    ‘label’: ‘Click Me!’</pre><pre>})</pre><p>Unfortunately this does mean some work will have to happen to update all views using the old macros, but to mitigate the impact of this, Pulsar’s macros (effectively, its API) will be versioned so that a product (like Q) can have some views running v1 while others are updated to use v2 and not have to lock their Pulsar dependency to <strong>~2.*</strong> and miss out on any new features or bug fixes. Once the relevant teams sound the horn to say they’re no longer using v1 macros, they’ll be removed.</p><p>The new versions sit in a <strong>v2</strong> directory, the actual path will depend on how you’re pulling Pulsar into your product, but for example:</p><p><strong>Version 1</strong></p><pre>{% import ‘@pulsar/helpers/html.html.twig’ as html %}</pre><p><strong>Version 2</strong></p><pre>{% import ‘@pulsar/v2/helpers/html.html.twig’ as html %}</pre><p>Think you have what it takes to work on a UI platform that will be used by a company full of engineers across many different products?</p><p>You should totally <a href="https://twitter.com/jaducareers">talk to us</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f2c336dfb5d8" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pulsar/polishing-the-pulsar-f2c336dfb5d8">Polishing the pulsar</a> was originally published in <a href="https://medium.com/pulsar">Pulsar</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>