k Come May 11, post-production work in films will resume By www.thehindu.com Published On :: Fri, 08 May 2020 23:58:14 +0530 CM takes decision following representations from industry Full Article Tamil Nadu
k HC seeks report on sanitisation measures taken at temporary markets By www.thehindu.com Published On :: Fri, 08 May 2020 23:59:05 +0530 The Madras High Court on Friday granted time till Monday for the State government to file a comprehensive report on steps taken to conduct mass testin Full Article Tamil Nadu
k Second train with migrant workers leaves for Ranchi By www.thehindu.com Published On :: Sat, 09 May 2020 05:22:35 +0530 The second Shramik special train with 1,131 passengers left Kadpadi junction for Ranchi on Friday at 7.40 p.m. The passengers were brought to the stat Full Article Tamil Nadu
k [ASAP] Low-Threshold Lasing up to 360 K in All-Dielectric Subwavelength-Nanowire Nanocavities By dx.doi.org Published On :: Tue, 07 Apr 2020 04:00:00 GMT ACS PhotonicsDOI: 10.1021/acsphotonics.0c00166 Full Article
k [ASAP] Size, Ligand, and Defect-Dependent Electron–Phonon Coupling in Chalcogenide and Perovskite Nanocrystals and Its Impact on Luminescence Line Widths By dx.doi.org Published On :: Mon, 13 Apr 2020 04:00:00 GMT ACS PhotonicsDOI: 10.1021/acsphotonics.0c00034 Full Article
k [ASAP] Gain-Assisted Optomechanical Position Locking of Metal/Dielectric Nanoshells in Optical Potentials By dx.doi.org Published On :: Mon, 04 May 2020 04:00:00 GMT ACS PhotonicsDOI: 10.1021/acsphotonics.0c00213 Full Article
k [ASAP] Strong Optical Feedback Stabilized Quantum Cascade Laser By dx.doi.org Published On :: Fri, 08 May 2020 04:00:00 GMT ACS PhotonicsDOI: 10.1021/acsphotonics.0c00189 Full Article
k Making a Better Custom Select Element By feedproxy.google.com Published On :: Sun, 01 Dec 2019 12:00:00 +0000 Julie Grundy kicks off this, our fifteenth year, by diving headlong into the snowy issue of customising form inputs. Nothing makes a more special gift at Christmas that something you’ve designed and customised yourself. But can it be done while staying accessible to every user? In my work as an accessibility consultant, there are some frequent problems I find on people’s websites. One that’s come up a lot recently is that people are making custom select inputs for their forms. I can tell that people are trying to make them accessible, because they’ve added ARIA attributes or visually-hidden instructions for screen reader users. Sometimes they use a plugin which claims to be accessible. And this is great, I love that folks want to do the right thing! But so far I’ve never come across a custom select input which actually meets all of the WCAG AA criteria. Often I recommend to people that they use the native HTML select element instead. Yes, they’re super ugly, but as Scott Jehl shows us in his article Styling a Select Like It’s 2019 they are a lot easier to style than they used to be. They come with a lot of accessibility for free – they’re recognised and announced clearly by all screen reader software, they work reliably and predictably with keyboards and touch, and they look good in high contrast themes. But sometimes, I can’t recommend the select input as a replacement. We want a way for someone to choose an item from a list of options, but it’s more complicated than just that. We want autocomplete options. We want to put images in there, not just text. The optgroup element is ugly, hard to style, and not announced by screen readers. The focus styles are low contrast. I had high hopes for the datalist element, but although it works well with screen readers, it’s no good for people with low vision who zoom or use high contrast themes. Figure 1: a datalist zoomed in by 300% Select inputs are limited in a lot of ways. They’re frustrating to work with when you have something which looks almost like what you want, but is too restricted to be useful. We know we can do better, so we make our own. Let’s work out how to do that while keeping all the accessibility features of the original. Semantic HTML We’ll start with a solid, semantic HTML base. A select input is essentially a text input which restricts the possible answers, so let’s make a standard input. <label for="custom-select">User Type</label> <input type="text" id="custom-select"> Then we need to show everyone who can see that there are options available, so let’s add an image with an arrow, like the native element. <label for="custom-select">User Type</label> <input type="text" id="custom-select"> <img src="arrow-down.svg" alt=""> For this input, we’re going to use ARIA attributes to represent the information in the icon, so we’ll give it an empty alt attribute so screen readers don’t announce its filename. Finally, we want a list of options. An unordered list element is a sensible choice here. It also lets screen reader software understand that these bits of text are related to each other as part of a group. <ul class="custom-select-options"> <li>User</li> <li>Author</li> <li>Editor</li> <li>Manager</li> <li>Administrator</li> </ul> You can dynamically add or remove options from this list whenever you need to. And, unlike our <option> element inside a <select>, we can add whatever we like inside the list item. So if you need images to distinguish between lots of very similar-named objects, or to add supplementary details, you can go right ahead. I’m going to add some extra text to mine, to help explain the differences between the choices. This is a good base to begin with. But it looks nothing like a select input! We want to make sure our sighted users get something they’re familiar with and know how to use already. Styling with CSS I’ll add some basic styles similar to what’s in Scott Jehl’s article above. We also need to make sure that people who customise their colours in high contrast modes can still tell what they’re looking at. After checking it in the default Windows high contrast theme, I’ve decided to add a left-hand border to the focus and hover styles, to make sure it’s clear which item is about to be chosen. This would be a good time to add any dark-mode styles if that’s your jam. People who get migraines from bright screens will thank you! JavaScript for behaviour Of course, our custom select doesn’t actually do anything yet. We have a few tasks for it: to toggle the options list open and closed when we click the input, to filter the options when people type in the input, and for selecting an option to add it to the input and close the list. I’m going to tackle toggling first because it’s the easiest. Toggling Sometimes folks use opacity or height to hide content on screen, but that’s like using Harry Potter’s invisibility cloak. No-one can see what’s under there, but Harry doesn’t cease to exist and you can still poke him with a wand. In our case, screen reader and keyboard users can still reach an invisible list. Instead of making the content see-through or smaller, I’m going to use display: none to hide the list. display: none removes the content from the accessibility tree, so it can’t be accessed by any user, not just people who can see. I always have a pair of utility classes for hiding things, as follows: .hidden-all { display: none; } .hidden-visually { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; -webkit-clip-path: inset(50%); clip-path: inset(50%); border: 0; } So now I can just toggle the CSS class .hidden-all on my list whenever I like. Browsing the options Opening up our list works well for our mouse and touch-screen users. Our styles give a nice big tap target for touch, and mouse users can click wherever they like. We need to make sure our keyboard users are taken care of though. Some of our sighted users will be relying on the keyboard if they have mobility or dexterity issues. Usually our screen reader users are in Browse mode, which lets them click the arrow keys to navigate through content. However, custom selects are usually inside form elements. which pushes screen reader software to Forms Mode. In Forms mode, the screen reader software can only reach focusable items when the user clicks the Tab key, unless we provide an alternative. Our list items are not focusable by default, so let’s work on that alternative. To do this, I’m adding a tabindex of -1 to each list item. This way I can send focus to them with JavaScript, but they won’t be part of the normal keyboard focus path of the page. csOptions.forEach(function(option) { option.setAttribute('tabindex, '-1') }) Now I can move the focus using the Up and Down arrow keys, as well as with a mouse or tapping the screen. The activeElement property of the document is a way of finding where the keyboard focus is at the moment. I can use that to loop through the elements in the list and move the focus point forward or back, depending on which key is pressed. function doKeyAction(whichKey) { const focusPoint = document.activeElement switch(whichKey) { case: 'ArrowDown': toggleList('Open') moveFocus(focusPoint, 'forward') break case: 'ArrowUp': toggleList('Open') moveFocus(focusPoint, 'back') break } } Selecting The Enter key is traditional for activating an element, and we want to match the original select input. We add another case to the keypress detector… case 'Enter': makeChoice(focusPoint) toggleList('Shut') setState('closed') break … then make a function which grabs the currently focused item and puts it in our text input. Then we can close the list and move focus up to the input as well. function makeChoice(whichOption) { const optionText = whichOption.documentQuerySelector('strong') csInput.value = optionText } Filtering Standard select inputs have keyboard shortcuts – typing a letter will send focus to the first item in the option which begins with that letter. If you type the letter again, focus will move to the next option beginning with that letter. This is useful, but there’s no clue to tell users how many options might be in this category, so they have to experiment to find out. We can make an improvement for our users by filtering to just the set of options which matches that letter or sequence of letters. Then sighted users can see exactly how many options they’ve got, and continue filtering by typing more if they like. (Our screen reader users can’t see the remaining options while they’re typing, but don’t worry – we’ll have a solution for them in the next section). I’m going to use the .filter method to make a new array which only has the items which match the text value of the input. There are different ways you could do this part – my goal was to avoid having to use regex, but you should choose whatever method works best for your content. function doFilter() { const terms = csInput.value const aFilteredOptions = aOptions.filter(option => { if (option.innerText.toUpperCase().startsWith(terms.toUpperCase())) { return true } }) // hide all options csOptions.forEach(option => option.style.display = "none") // re-show the options which match our terms aFilteredOptions.forEach(function(option) { option.style.display = "" }) } Nice! This is now looking and behaving really well. We’ve got one more problem though – for a screen reader user, this is a jumble of information. What’s being reported to the browser’s accessibility API is that there’s an input followed by some clickable text. Are they related? Who knows! What happens if we start typing, or click one of the clicky text things? It’s a mystery when you can’t see what’s happening. But we can fix that. ARIA ARIA attributes don’t provide much in the way of additional features. Adding an aria-expanded='true' attribute doesn’t actually make anything expand. What ARIA does is provide information about what’s happening to the accessibility API, which can then pass it on to any assistive technology which asks for it. The WCAG requirements tell us that when we’re making custom elements, we need to make sure that as a whole, the widget tells us its name, its role, and its current value. Both Chrome and Firefox reveal the accessibility tree in their dev tools, so you can check how any of your widgets will be reported. We already have a name for our input – it comes from the label we associated to the text input right at the start. We don’t need to name every other part of the field, as that makes it seem like more than one input is present. We also don’t need to add a value, because when we select an item from the list, it’s added to the text input and therefore is exposed to the API. Figure 2: How Firefox reports our custom select to assistive technology. But our screen readers are going to announce this custom select widget as a text entry field, with some images and a list nearby. The ARIA Authoring Practices site has a pattern for comboboxes with listboxes attached. It tells you all the ARIA you need to make screen reader software give a useful description of our custom widget. I’m going to add all this ARIA via JavaScript, instead of putting it in the HTML. If my JavaScript doesn’t work for any reason, the input can still be a plain text field, and we don’t want screen readers to announce it as anything fancier than that. csSelector.setAttribute('role', 'combobox') csSelector.setAttribute('aria-haspopup', 'listbox') csSelector.setAttribute('aria-owns', '#list') csInput.setAttribute('aria-autocomplete', 'both') csInput.setAttribute('aria-controls', 'list') The next thing to do is let blind users know if the list is opened or closed. For that task I’m going to add an aria-expanded attribute to the group, and update it from false to true whenever the list changes state in our toggling function. The final touch is to add a secret status message to the widget. We can use it to update the number of options available after we’ve filtered them by typing into the input. When there are a lot of options to choose from, this helps people who can’t see the list reducing know if they’re on the right track or not. To do that we first have to give the status message a home in our HTML. <div id='custom-select-status' class='hidden-visually' aria-live='polite'></div> I’m using our visually-hidden style so that only screen readers will find it. I’m using aria-live so that it will be announced as often as it updates, not just when a screen reader user navigates past it. Live regions need to be present at page load, but we won’t have anything to say about the custom select then so we can leave it empty for now. Next we add one line to our filtering function, to find the length of our current list. updateStatus(aFilteredOptions.length) Then we send that to a function which will update our live region. function updateStatus(howMany) { console.log('updating status') csStatus.textContent = howMany + " options available." } Conclusion Let’s review what we’ve done to make an awesome custom select input: Used semantic HTML so that it’s easily interpreted by assistive technology while expanding the types of content we can include in it Added CSS styles which are robust enough to survive different visual environments while also fitting into our branding needs Used JavaScript to provide the basic functionality that the native element has Added more JavaScript to get useful functionality that the native element lacks Carefully added ARIA attributes to make sure that the purpose and results of using the element are available to assistive technology and are updated as the user interacts with it. You can check out my custom select pattern on GitHub – I’ll be making additions as I test it on more assistive technology, and I welcome suggestions for improvements. The ARIA pattern linked above has a variety of examples and customisations. I hope stepping through this example shows you why each of the requirements exists, and how you can make them fit your own needs. I think the volume of custom select inputs out there shows the ways in which the native select input is insufficient for modern websites. You’ll be pleased to know that Greg Whitworth and Simon Pieters are working on improving several input types! You can let them know what features you’d like selects to have. But until that work pays off, let’s make our custom selects as accessible and robust as they can possibly be. About the author Julie Grundy is an accessibility expert who works for Intopia, a digital accessibility consultancy. She has over 15 years experience as a front-end web developer in the health and education sectors. She believes in the democratic web and aims to unlock digital worlds for as many people as possible. In her spare time, she knits very slowly and chases very quickly after her two whippets. More articles by Julie Full Article Code accessibility
k Making Distributed Working Work By feedproxy.google.com Published On :: Thu, 12 Dec 2019 12:00:00 +0000 Anna Debenham harnesses up the huskies and puts them to work to figure out how teams distributed across multiple locations can work effectively to all pull in the same direction. With modern workforces distributed from north pole to south, can they all be kept running in step? Four years ago, I started working at a small startup called Snyk that’s based in two locations – London and Tel Aviv. The founders made it clear they wanted to grow headcount in both locations at the same rate, and for the design and engineering skillsets between the two offices to be evenly spread. We’re now at over 200 people and we’re still staying true to that vision, but only by completely changing how we were used to working. The trend for fully distributed teams is on the rise – companies like InVision and GitLab have entirely remote employees. Snyk is somewhere in between, with small hubs of global team members in homes and shared offices globally alongside our main London, Tel Aviv, Boston, Ottawa and Bay Area offices. Our R&D teams are based entirely in London or Tel Aviv, with a few employees working around Europe. Rather than have Team A working in one office and Team B working in another, we’ve deliberately designed it so that no R&D team at Snyk has all its members in one location. We could design our teams to be all co-located so that everyone’s in the same room, but we don’t. When I explain this setup to people, I’ll often get a response of bewilderment – why do it this way? It sounds like a pain! Increasingly though, the reaction is positive – usually from people who’ve worked in a distributed team before where departments are split neatly between locations. They’ve experienced an “us vs them” culture, with work being thrown over the fence to designers or engineers in different timezones. They’ve been at the mercy of the decision makers who are all in the head office. This is exactly what we wanted to avoid. We wanted the company to feel like one team, across many locations. It’s not perfect – I do miss the things that working in the same location brings such as collaborating on a whiteboard, or having planning documents stuck on the wall for the team to refer to. Pre-distributed working, I used to sit next to a designer and we’d bounce ideas off each other. Now I have to make the extra effort to schedule something in. Managing people remotely is also tough – I can’t easily see that a team member is having a bad day and make them a cup of tea. But on the whole, it works pretty well for us. The time difference between London and Tel Aviv is a comfy 2 hours, and in Tel Aviv, the week runs from Sunday to Thursday, meaning there’s just a single day in the week when all our teams aren’t working. This makes the week feel like the ebb and flow of a tide – my Mondays are very busy, but on Fridays, half the team is off so there are barely any meetings – ideal for deep focus time. So how do we make this distributed-but-also-co-located hybrid thing work? Level the playing field Firstly, that “us vs them” mentality I mentioned is the key thing to avoid to maintain a positive distributed work culture. Avoid the term “remote team”, as that has a sense of otherness. Instead, refer to your team as “distributed”. It’s such a small change that has the effect of bringing everyone onto the same level. Also, consider your video conferencing etiquette – if you’ve got a large part of your team in one location, with just one or two members who are dialling in, you could end up with a very one-sided conversation. The room with the most people in it has a habit of forgetting the person they can’t easily see. Even if you’re in the same room, dial in individually so that everyones faces are the same size, and you’re addressing all the participants rather than just those in the same room as you. Invest in tools that help communication Early on, we invested in tools that would help make communication between locations as seamless as possible. I’m not talking about those screens with wheels that follow co-workers around a room to recreate a manager breathing down their neck (although now I think of it…). I’m talking about the familiar ones like Slack, Zoom and Notion. Use a single tool where possible to reduce friction between teams so there’s no confusion as to whether you’re having a call over Google Hangouts, Zoom, Skype or whatever else is fashionable to use this year. Same with meeting notes – keep them in one place rather than scattered across Dropbox, Email and Google Docs. Remote pair programming has also got a lot easier. We used ScreenHero before it got acquired and lost its remote control functionality – but there are some great alternatives out there like USE Together. You might also have collaboration tools built into your code editor, like Visual Studio’s Live Share, and Atom’s Teletype. If teams are complaining about bad audio, don’t skimp – invest in better microphones, speakers and sound-proofing. You won’t get the benefits of working as a distributed team if there’s a barrier between communication. Ensure the internet is stable in all locations. Also, it sounds basic but make sure teams have somewhere to take a call in the first place, particularly 1:1s which shouldn’t be done in the open. Previous places I’ve contracted at had people dialling into meetings in stairwells, shower rooms and even toilet cubicles. Take care not to make the experience of working in a distributed team end up harming the experience of working in an office. Open a window For as long as we’ve had offices, we’ve had a fixed camera and TV screen setup between them that acts as a “window” between locations. The camera is on all the time, and we turn the microphone on once a day for standup (or whenever someone wants to say hi). When I turn on the TV in the morning, I can see the Tel Aviv office already working. At midday, our Boston office comes online, followed shortly after by our Ottawa office. It’s incredible what a difference this has made to make us feel more like one office. We’ve positioned one of the cameras next to our dining area so we can eat together. Another camera is honed in on a dog bed in the corner of the office (sometimes there’s a dog in it!). Distributed meetings With the time differences and weekday shift, there’s a condensed timeframe in which we can collaborate. It’s not as bad as it could be (I pity my fellow Londoners who work for companies based in California), but the hours between 9am and 4pm Monday to Thursday for us are at a premium. This means the meetings we have need to be a good use of everyone’s time. When we can’t find a time that works for everyone, we record the meeting. But even if everyone can make it, we still take notes. The notebook brand Field Notes have a slogan “I’m not writing it down to remember it later, I’m writing it down to remember it now.”. This is a reminder that it’s not always the notes themselves that are useful, but the act of taking them. Where they’re really powerful is when you share them in real time. In Kevin Hoffman’s book ‘Meeting Design’, he recommends the notetaker shares their screen while taking notes so that everyone can participate in making sure those notes are accurate. Having the notes on the screen also helps focus the conversation – particularly if you have an agenda template to start with. It means you’ve got a source of truth for someone who mis-remembers a conversation, and you’ve got something to look back on in the next meeting so you don’t repeat yourselves. Another tip we’ve taken from Kevin’s book is to have a kanban board for standing meetings, where everyone can add a topic. That way, you always have a backlog of topics to discuss in the meeting. If there aren’t any, you can cancel the meeting! We use Notion’s kanban template for our sync meeting notes. Anyone can add a topic before (or during) the meeting and we go through each of them in order. We add notes and action points to the topic card. Don’t get into bad habits when you’re lucky enough to be sharing a single space – keep documenting conversations and decisions in the same way you would with a distributed team, so that future you can remember, and future team members can gather that context. Team bonding I always think the best way to bonding with people is over a meal – isn’t that what Christmas dinner is great for? As a distributed team, we can’t do that. We could try and recreate it (even just for the comedy value), but it’s really not the same. We have to try something different. Enter Eurovision. For those of you outside Europe, imagine a cheesy pop song contest where each country performs their own song and everyone votes for the winner. This year, it was held in Tel Aviv, so dozens of us sat down to watch the live stream. We set up a Eurovision Slack channel and shared our horror in real time. But Eurovision only happens ones a year, so we’ve extended shared experiences into multiple “hobby” Slack channels: we have one for food fans (#fun-foodies), football fans (#fun-footies), and even sourdough fans (#fun-sourdough). There’s also a weekly “drink and sync” where office-less team members join a video call and chat over a beer, coffee, or juice depending on the time of day for those that dial in. One team runs a movie club where they choose a video that’s relevant to their team’s work (such as a conference talk) and watch it together at the same time. Onboarding new team members can feel quite impersonal if their manager isn’t in the same office. Starting your first day in an office full of strangers, where the only interaction with your manager is over a video call can feel daunting. And as a manager, I get anxious about my new hire’s first day – was there someone there to greet them and show them where they sit? Was everything set up for them? Did they have someone to eat lunch with? So we’ve been rolling out an “onboarding buddy” scheme. This is someone local who can help the new hire settle in to their new surroundings. It’s someone to chat to, share a coffee with, and generally look out for them. We also use a Slack app called Donut which pairs employees up for informal chats to get to know each other. You get paired with someone random in the company and it helps you schedule a call with them. This is to encourage cross-pollination across teams and locations. What distributed teamwork has taught us There’s a lot that we’ve learnt about working well as a distributed team. We try and recreate the good things about sharing a physical space, and make them feel just as natural in the digital space, while also compensating for the lack of intimacy from being thousands of miles apart. Mel Choyce’s 24 ways article Surviving—and Thriving—as a Remote Worker stresses the value of remote working, and the long term benefits it has had. Working remotely has made me a better communicator largely because I’ve gotten into the habit of making written updates. I think in a lot of ways, the distance has brought us closer. We make more of an effort to check in on how each other is doing. We document as much as we can, which really helps new hires get up to speed quickly. By identifying what we find valuable about working in the same room, and translating that to work across locations, we find collaboration easier because we’re no longer strangers to each other. We might not be able to have those water-cooler moments in the physical realm, but we’ve done a good job of replicating that online. About the author Anna Debenham lives in London and is a Product Manager at Snyk. She’s the author of Front-end Style Guides, and when she’s not playing on them, she’s testing as many game console browsers as she can get her hands on. More articles by Anna Full Article Process productivity
k Design Tokens and Component Based Design By feedproxy.google.com Published On :: Sat, 14 Dec 2019 12:00:00 +0000 Stuart Robson rolls up his sleeves and begins to piece together the jigsaw puzzle that is design tokens and component based design. Starting with the corners, and working around the edges, Stu helps us to piece together a full picture of a modern design system. If you stare at your twitter feed long enough, it can look like everyone is talking about Design Systems. In some cases you could be persuaded to think how shallow the term can go. “Isn’t this what we called Style Guides?”, “Here’s my React Design System”, “I’ve just updated the Design System in Sketch” To me, they are some and all of these things. Over the last 4 years of consulting with two clients on their Design System, my own view has changed a little. If you dig a little deeper into Design Systems twitter you will probably see the term “Design Tokens” pop up at least once a day somewhere. Design Tokens came out of work that was being done at Salesforce with Jina and others who pioneered the creation of Design Tokens as we know them today – creating the first command line tool in Theo that had started the adoption of Design Tokens to the wider Design Systems Community. A cool term but, what are they? If you look at your client work, your companies site, the project you’re working on you should notice some parts of the page have a degree of consistency: the background colour of your form buttons is the same colour as your link text, or your text has the same margin, or your card elements have the same spacing as your media object. These are design decisions, and they should be littered across the overall design of your project. These decisions might start off in a Sketch file and make their way into code from detailed investigation of a Sketch file, or you may find that the design evolves from your design application once it gets into code. These design decisions can change, and to keep them synchronised across design and development in applications, as well as a larger documentation site in your Design System, is going to take some effort. This is where Design Tokens come in, and I find the best way to succinctly reiterate what they are is via the two following quotes… “Design Tokens are an abstraction for everything impacting the visual design of an app/platform.” – Sönke Rohde …and “We use them in place of hard-coded values in order to maintain a scale-able and consistent visual system.” – Jina There are several global design decisions that we can abstract to create a top level design token – Sizing, Font Families, Font Styles, Font Weights, Font Sizes, Line Heights, Border Styles, Border Colours, Border Radius, Horizontal Rule Colours, Background Colours, Gradients, Background Gradients, Box Shadows, Filters, Text Colours, Text Shadow, Time, Media Queries, Z Index, Icons – these can all be abstracted as required. So, spicy Sass variables? We can look at Design Tokens as an abstraction of CSS, sort of like Sass variables, but spicier. Looking at them like this we can see that they are (in either .yaml or .json) a group of related key value pairs with more information that can be added as needed. The great thing with abstracting design decisions outside of your CSS pre-processor is that you’re not tying those decisions to one platform or codebase. As a crude example, we can see here that we are defining a name and a value that could then become our color, background-color, or border-color, and more. # Colours # ------- - name: color-red value: #FF0000 - name: color-green value: #00FF00 - name: color-blue value: #0000FF - name: color-white value: #FFFFFF - name: color-black value: #000000 These can then generate our Sass variables (as an example) for our projects. $color-red: #FF0000 !default; $color-green: #00FF00 !default; $color-blue: #0000FF !default; $color-white: #FFFFFF !default; $color-black: #000000 !default; Why are they so good Ok, so we now know what Design Tokens are, but why do we need them? What makes them better than our existing solutions (css pre-processors) for defining these design decisions? I think there are 5 really good reasons why we all should start abstracting these design decisions away from the CSS that they may live in. Some of these reasons are similar to reasons some developers use a pre-processor like Sass, but with added bonuses. Consistency Much like using a CSS pre-processor or using CSS custom properties, being able to define a background colour, breakpoint, or font-size in more than one place using the same key ensures that we are using the Sass values across the entire product suite we are developing for. Using our Design Tokens in their generated formats, we can be sure to not end up with 261 shades of blue. Maintainability By using a pre-processor like Sass, or using native CSS custom properties, we can already have maintainable code in our projects. Design Tokens also do this at the abstracted level as well. Scalability “Design Tokens enable us to scale our Design across all the permutations.” – Jina At this point, we’re only talking about abstracting the design decisions for use in CSS. Having Design Tokens allows design to scale for multiple brands or multiple projects as needed. The main benefit of Design Tokens in regards to scalability is the option that it gives us to offer the Design Tokens for other platforms and frameworks as needed. With some of the tools available, we can even have these Tokens shared between applications used by designers and developers. Your marketing site and your iOS application can soon share the same design decisions codified, and you can move towards creating an Android app or web application as required. Documentation If we abstract the design decisions from one platform specific programming language it would be no good if it wasn’t made to be easily accessible. The tools and applications available that are mentioned later in this article can now create their own documentation, or allow you to create your own. This documentation is either hosted within a web-based application or can be self-hosted with the rest of your Design Systems documentation. Most of the command line tools go further and allow you do add more details that you wish to convey in the documentation, making it as unique as it is required for your project. Empowerment When you abstract your design decisions to Design Tokens, you can help empower other people on the project. With the tools available today, and the tools that are just around the corner, we can have these design decisions determined by anyone on the team. No-one necessarily needs to understand how to set up the codebase to update the colour slightly. Some of the tools I mention later on allow you to update the Design Tokens in the browser. Design Systems are already “bridging the gap” between design and development. With Design Tokens and the tooling available, we can create better team relationships by closing that gap instead. Some of the benefits of creating and using Design Tokens are the same as using a pre-processor when it comes to authoring CSS. I feel the added bonuses of being able to empower other team members and document how you use them, as well as the fundamental reasoning in that they can be platform agnostic, are all great “selling points” to why you need to start using Design Tokens today. Tools There are several tools available to help you and your team to create the required files from your abstracted Design Tokens: Command Line Tools There are several tools available on the command line that can be used as part of, or separate to, your development process. These tools allow you to define the Design Tokens in a .json or .yaml file format which can then be compiled into the formats you require. Some have built in functions to turn the inputted values to something different when compiled – for example, turning hexadecimal code that is a Design Token into a RGB value in your .css file. These command line tools, written in JavaScript, allow you to create your own ways in which you want things transformed. My current client has certain design decisions for typography in long form content (font size, weight, line height and margins) which need to be together to make sense. Being able to write JavaScript to compile these design decisions into an independent Sass map for each element allows us to develop with assurance that the long form content has the correct styling. WYSIWYG Tools WYSIWYG (What You See Is What You Get Tools) have been around for almost as long as we have been able to make websites. I can just about remember using Dreamweaver 2, before I knew what a <table> was. When browsers started to employ vendor prefixes to new CSS for their browsers, a flurry of online WYSIWYG tools came with it built in. They’re still there, but the industry has moved on. Design Tokens also have a few WYSIWYG tools available. From simpler online tools that allow you to generate the correct Sass variables needed for your design decisions to tools that store your decisions online and allow you to export them as npm packages. These types of tools for creating Design Tokens can help empower the team as a whole, with some automatically creating documentation which can easily be shared with a url. Retrofitting Tools If you are starting from scratch on a new re-design or on a new project that requires a Design System and Tokens, the many of the tools mentioned above will help you along your way. But what if you’re in the middle of a project, or you have to maintain something and want to start to create the parts required for a Design System? Luckily there are several tools and techniques to help you make a start. One new tool that might be useful is Superposition. Currently in private beta with the public release set for Q1 of 2020 Superposition helps you “Extract design tokens from websites and use them in code and in your design tool.” Entering your domain gives you a nice visual documentation of your sites styles as Design Tokens. These can then be exported as Sass Variables, CSS Custom Properties, JavaScript with the team working on exports to iOS and Android. If you have an existing site, this could be a good first step before moving to one of the other tools mentioned above. You could also make use of CSSStats or Project Wallace’s Analysis page that I mentioned earlier. This would give you an indication of what Design Tokens you would need to implement. Component Based Design So, we’ve created our Design Tokens by abstracting the design decisions of brand colours, typography, spacing and more. Is that as far as we can go? Levels of Design Decisions Once we have created our first set of Design Tokens for our project, we can take it that little bit deeper. With command line tools and some of the applications available, you can link these more global decisions to a more deeper level. For example, you can take your chosen colours and make further design decisions on the themes of your project, such as what the primary, secondary, or tertiary colours are or what your general component and layout spacing will be. With this, we can go one step further. We could also define some component specific design decisions that can then be compiled for the developer to use. Invest in time to check over the designs with a fine toothcomb and make sure you are using the correct Sass variable or CSS custom property for that component. If you are going more than one or two levels of design decision making, you can compile each set of these Design Tokens to your Sass variables which can then be used as required. So you can provide: global, theme, component level Sass variables which can be used in the project. Or you could choose to only compile what you need for the components you are creating. Variables, Maps, Custom Properties Some of the tools available for creating and maintaining your Design Tokens allow you to compile to certain programming languages. With my current client work, I am making use of Sass variables, Sass maps, and CSS custom properties. The Design Tokens are compiled into one or more of these options depending on how they will be used. Colours are compiled as global Sass variables, inside of a couple of Sass maps and CSS custom properties. Our macro layout breakpoints are defined as a single Sass map. If we know we are creating a component that has the ability to be themed, we can make use of CSS custom properties to reduce the amount of CSS we need to override, and also allow us to inline things that can be changed via a CMS as required. Which leaves us using Sass variables for parts of a component that won’t change. We are using Sass maps differently still. As mentioned, we generate a Sass map containing the design decisions for each element of text, and we can use long form text. This Sass map is then compiled into separate CSS declarations as needed using Sass mixins. I find the beauty of being able to make use of the global, themed, and component level design decisions by compiling them into various formats (that essentially become CSS) and that gives us more power in authoring components. Creating Consistent Utility Classes As you have created your more global generic design decisions, you can create your own small set of utility classes. Using a pre-processor like Sass you can define a set of mixins and functions that can take your Design Tokens that have been compiled down into variables and maps and generate separate classes for each design decision. By making tokens available to all digital teams, we can enable them to create custom experiences that are aligned to current visual standards when a component does not (or will not) exist in the design system. Maya King In creating utility classes with Design Tokens (using something like Sass) you have consistency with the overall Design System for times when you or a team need to create a one-off component for a project. These exceptions tend to be something that won’t make it as part of the overall Design System, but it still needs that look and feel. Having classes available that we can guarantee use the generic, global design decisions from the Design Tokens means these one-off components should be well on their way to have the overall look and feel of the project, and will get any updates with little to no additional overhead. Wrapping Up I think we are starting to see the potential of using Design Tokens as Design Systems become even more popular. I think that, from this overview, we can see how they can help us close the gap that still exists in places between the designers and developers on the team. They can help empower people who do not code to make changes that can be automatically updating live work. I think you can start now. You may not have or need what you could term “a fully-fledged Design System” but this small step will help move towards one in the future and give you instant benefits of consistency and maintainability now. If you want more Design Tokens, as well as the links that are dotted around this article I also maintain a GitHub repo of Awesome Design Tokens which I try to keep updated with links to tools, articles, examples, videos, and anything else that’s related to Design Tokens. About the author Stuart Robson is a freelance front-end developer and design systems advocate who curates the design systems newsletter - news.design.systems More articles by Stuart Full Article Design style-guides
k Addiction debates : hot topics from policy to practice / Catherine Comiskey. By darius.uleth.ca Published On :: Thousand Oaks : SAGE Publishing, 2019 Full Article
k Cigarette taxes and smoking among sexual minority adults [electronic resource] / Christopher Carpenter, Dario Sansone By darius.uleth.ca Published On :: Cambridge, Mass. : National Bureau of Economic Research, 2020 Full Article
k The effects of e-cigarette taxes on e-cigarette prices and tobacco product sales [electronic resource] : evidence from retail panel data / Chad D. Cotti, Charles J. Courtemanche, Johanna Catherine Maclean, Erik T. Nesson, Michael F. Pesko, Nathan Tefft By darius.uleth.ca Published On :: Cambridge, Mass. : National Bureau of Economic Research, 2020 Full Article
k Effect of prescription opioids and prescription opioid control policies on infant health [electronic resource] / Engy Ziedan, Robert Kaestner By darius.uleth.ca Published On :: Cambridge, Mass. : National Bureau of Economic Research, 2020 Full Article
k Cigarette taxes and teen marijuana use [electronic resource] / D. Mark Anderson, Kyutaro Matsuzawa, Joseph J. Sabia By darius.uleth.ca Published On :: Cambridge, Mass. : National Bureau of Economic Research, 2020 Full Article
k MANHATTAN COM. ACCESS, ET AL. v. HALLECK, DEEDEE, ET AL.. Decided 06/17/2019 By www.law.cornell.edu Published On :: Mon, 17 Jun 2019 00:00:00 EDT Full Article
k KNICK, ROSE MARY v. SCOTT, PA, ET AL.. Decided 06/21/2019 By www.law.cornell.edu Published On :: Fri, 21 Jun 2019 00:00:00 EDT Full Article
k NORTH CAROLINA DEPT. OF REVENUE v. KAESTNER FAMILY TRUST. Decided 06/21/2019 By www.law.cornell.edu Published On :: Fri, 21 Jun 2019 00:00:00 EDT Full Article
k IANCU, ANDREI v. BRUNETTI, ERIK. Decided 06/24/2019 By www.law.cornell.edu Published On :: Mon, 24 Jun 2019 00:00:00 EDT Full Article
k FOOD MARKETING INSTITUTE v. ARGUS LEADER MEDIA. Decided 06/24/2019 By www.law.cornell.edu Published On :: Mon, 24 Jun 2019 00:00:00 EDT Full Article
k KISOR, JAMES L. v. WILKIE, SEC. OF VA. Decided 06/26/2019 By www.law.cornell.edu Published On :: Wed, 26 Jun 2019 00:00:00 EDT Full Article
k DEPARTMENT OF COMMERCE v. NEW YORK. Decided 06/27/2019 By www.law.cornell.edu Published On :: Thu, 27 Jun 2019 00:00:00 EDT Full Article
k Reluctant warriors: Germany, Japan, and their U.S. alliance dilemma / Alexandra Sakaki, Hanns W. Maull, Kerstin Lukner, Ellis S. Krauss, Thomas U. Berger By library.mit.edu Published On :: Sun, 22 Mar 2020 07:44:49 EDT Dewey Library - UA710.S135 2020 Full Article
k Power to the people: how open technological innovation is arming tomorrow's terrorists / Audrey Kurth Cronin By library.mit.edu Published On :: Sun, 22 Mar 2020 07:44:49 EDT Dewey Library - U39.C76 2020 Full Article
k The modern Republican Party in Florida / Peter Dunbar and Mike Haridopolos By library.mit.edu Published On :: Sun, 22 Mar 2020 07:44:49 EDT Dewey Library - JK2358.F5 D86 2019 Full Article
k #MeToo, Weinstein and feminism / Karen Boyle By library.mit.edu Published On :: Sun, 22 Mar 2020 07:44:49 EDT Dewey Library - HV6250.4.W65 B69 2019 Full Article
k Age of iron: on conservative nationalism / by Colin Dueck By library.mit.edu Published On :: Sun, 22 Mar 2020 07:44:49 EDT Dewey Library - JC573.2.U6 D8354 2020 Full Article
k Faithful fighters: identity and power in the British Indian Army / Kate Imy By library.mit.edu Published On :: Sun, 22 Mar 2020 07:44:49 EDT Dewey Library - UA668.I49 2019 Full Article
k No visible bruises: what we don't know about domestic violence can kill us / Rachel Louise Snyder By library.mit.edu Published On :: Sun, 22 Mar 2020 07:44:49 EDT Dewey Library - HV6626.2.S59 2019 Full Article
k How to democratize Europe / Stephanie Hennette, Thomas Piketty, Guillaume Sacriste, Antoine Vauchez By library.mit.edu Published On :: Sun, 29 Mar 2020 07:44:51 EDT Online Resource Full Article
k Prisoners of politics: breaking the cycle of mass incarceration / Rachel Elise Barkow By library.mit.edu Published On :: Sun, 29 Mar 2020 07:44:51 EDT Online Resource Full Article
k The sovereignty game: Neo-Colonialism and the Westphalian System / Will Hickey By library.mit.edu Published On :: Sun, 29 Mar 2020 07:44:51 EDT Online Resource Full Article
k A concise history of revolution / Mehran Kamrava By library.mit.edu Published On :: Sun, 29 Mar 2020 07:44:51 EDT Dewey Library - JC491.K255 2020 Full Article
k Automation and utopia: human flourishing in a world without work / John Danaher By library.mit.edu Published On :: Sun, 29 Mar 2020 07:44:51 EDT Online Resource Full Article
k Extreme reactions: radical right mobilization in Eastern Europe / Lenka Bustikova, Arizona State University By library.mit.edu Published On :: Sun, 29 Mar 2020 07:44:51 EDT Dewey Library - JC573.2.E852 B88 2020 Full Article
k Freedom, peace, and secession: new dimensions of democracy / Burkhard Wehner By library.mit.edu Published On :: Sun, 29 Mar 2020 07:44:51 EDT Online Resource Full Article
k The suspect: an Olympic bombing, the FBI, the media, and Richard Jewell, the man caught in the middle / Kent Alexander & Kevin Salwen By library.mit.edu Published On :: Sun, 29 Mar 2020 07:44:51 EDT Dewey Library - HV8079.B62 A44 2019 Full Article
k Reclaiming Liberalism David F. Hardwick, Leslie Marsh, editors By library.mit.edu Published On :: Sun, 5 Apr 2020 07:47:23 EDT Online Resource Full Article
k The lost soul of the American presidency: the decline into demagoguery and the prospects for renewal / Stephen F. Knott By library.mit.edu Published On :: Sun, 5 Apr 2020 07:47:23 EDT Dewey Library - JK511.K66 2019 Full Article
k Managing interdependencies in federal systems: intergovernmental councils and the making of public policy / Johanna Schnabel By library.mit.edu Published On :: Sun, 5 Apr 2020 07:47:23 EDT Online Resource Full Article
k Militarization: a reader / Roberto J. González, Hugh Gusterson, Gustaaf Houtman, editors ; in collaboration with Catherine Besteman, Andrew Bickford, Catherine Lutz, Katherine T. McCaffrey, Austin Miller, David H. Price, David Vine By library.mit.edu Published On :: Sun, 5 Apr 2020 07:47:23 EDT Dewey Library - U21.2.M558 2019 Full Article
k When they come for you: how police and government are trampling our liberties--and how to take them back / David Kirby By library.mit.edu Published On :: Sun, 5 Apr 2020 07:47:23 EDT Dewey Library - JC599.U5 K568 2019 Full Article
k Citizenship: what everyone needs to know / Peter J. Spiro By library.mit.edu Published On :: Sun, 5 Apr 2020 07:47:23 EDT Dewey Library - JF801.S694 2020 Full Article
k Human rights in the age of platforms / edited by Rikke Frank Jørgensen ; foreword by David Kaye By library.mit.edu Published On :: Sun, 5 Apr 2020 07:47:23 EDT Dewey Library - JC571.H7695266 2019 Full Article
k The Oxford handbook of modern British political history, 1800-2000 / edited by David Brown, Gordon Pentland, and Robert Crowcroft By library.mit.edu Published On :: Sun, 12 Apr 2020 09:49:18 EDT Online Resource Full Article
k Reflections on socialism in the Twenty-First Century: facing market liberalism, rising inequalities and the environmental imperative / Claes Brundenius, editor By library.mit.edu Published On :: Sun, 12 Apr 2020 09:49:18 EDT Online Resource Full Article
k Soft target protection: theoretical basis and practical measures / edited by Ladislav Hofreiter, Viacheslav Berezutskyi, Lucia Figuli and Zuzana Zvaková By library.mit.edu Published On :: Sun, 12 Apr 2020 09:49:18 EDT Online Resource Full Article
k Handbook of military sciences edited by Anders Sookermany By library.mit.edu Published On :: Sun, 12 Apr 2020 09:49:18 EDT Online Resource Full Article
k Sovereignty in the south: intrusive regionalism in Africa, Latin America, and Southeast Asia / Brooke N. Coe By library.mit.edu Published On :: Sun, 12 Apr 2020 09:49:18 EDT Dewey Library - JC327.C59 2019 Full Article
k Aiding and abetting: U.S. foreign assistance and state violence / Jessica Trisko Darden By library.mit.edu Published On :: Sun, 12 Apr 2020 09:49:18 EDT Dewey Library - JC599.D44 T75 2020 Full Article