hover-state-prototype:-invision,-framer,-sketch-and-figma

Practical examples of how to build a simple hover state prototype with some of the most popular prototyping tools on the market.


There are tons of options available for UX designers to prototype a user experience and you may not know what are the pros and cons of each tool just yet. The main goal of this post is to give you a taste of each tool’s prototyping workflow by taking you through the process of building a simple hover state example. By the end of these exercises, you should have a high-level idea of the jobs that are suitable for each of the tools.

Since the goal is to get a quick understanding of the prototyping tool’s workflow, we don’t need to be too fancy. A simple button hover prototype that alters the button background color should do the job. Below are the two component states we will be animating between.

The two states we’ll be prototyping

Here is a quick spec of the button background style:

  • Default background color: #3B42F4
  • Hover background color: #767BF8 (or 70% opacity of the default)

Instead of Invision Studio, we’ll do an Invision web example because it is the most popular prototyping tool based on 2018 Design Tools Survey. Since this is a screen linking tool, the only way to prototype the hover state is to build a hover link hotspot.

Step 1: Start by setting up two screens with each of the button states. You will need to design the buttons in another design tool of your choosing then upload the two states to Invision.

Step 2: Setup a hotspot over the default button with ‘Screen as Overlay’ link to the hover screen. Make sure to un-check the ‘Stay on target screen’ to allow the hover out.

Result: You should now have a functioning button hover state.

Pros:

Invision is fairly straightforward and that’s its advantage. You can essentially prototype hover states between any two static screens. Updating design is as easy as uploading a new mockup.

Cons:

The transition animation is limited and lacking sequence. Therefore if you require elements to transition one after another with fancier effects then this may not be the right tool of choice.


Framer has come a long way from being viewed as a super-advanced prototyping with code tool to now a design tool with prototyping capabilities. There are a couple of ways you can prototype a hover state in Framer X. We are going to go over the code override method because that’s more unique to Framer and it’s not too complex.

Step 1: Create the button designs as a Frame (Need to be in a frame to attach override to). We only need the default button here as we can apply the hover state as an override.

Step 2: With your button frame selected, hop over to the properties panel on the right and add an override. Go with the default ‘Example’ file, and for the override dropdown, choose the hover option.

Step 3: If you click on the preview prototype option at the top right corner (play icon) you can interact with this button and see it’s current hover state, which is a default scaling effect taken from the example override file.

Step 4: So far we’ve applied a hover state to your button design layer and applied an example hover override to it. Let’s look at the override code and modify it to meet our spec. From the Override properties panel, click on ‘Edit Code’. You should then see a code editor (don’t worry, we won’t be coding much to make this example work).

Step 5: What we need to do now is to modify the “Hover() function” starting on line 9 that looks like the code block below. Instead of the “whileHover: { scale: 0.8 }”, which monitors a mouse hover to the button layer and when it’s being hovered it scales the layer to 80% of its original size, we want to modify this to “whileHover: { opacity: 0.7 }” as shown below:

export function Hover(): Override {   return {      whileHover: { opacity: 0.7 },   }}

Result: The override now should adjust the opacity of the layer to 70% of the original opacity to simulate the hover effect we want.

Pros:

The override code components (not covered in this post) are flexible and powerful methods to build high-fidelity prototypes. You can prototype anything that’s feasible from a technical perspective.

The override on top of the design layer is a good half step to leverage some of the code-level prototyping features but not completely jumping into the full code setup.

Cons:

The coding part always have a bit of a learning curve for designers regardless of how elementary. While Framer is a powerful tool, it requires a good amount of time invested to learn the tool if the designer is new to coding.


Native prototyping feature was introduced since Sketch 49. However, the feature only supports artboard linking on click and lacks hover interaction. Therefore, to prototype hover animation we need to turn to Sketch plugins. There are a few animation plugins available. For this example, we will use the Anima plugin.

Step 1: You need to set up an artboard with the default button style.

Step 2: Assuming you have the plugin installed and activated. On the bottom right panel, you should see the Anima plugin section. We’ll use the interaction feature under the prototype tab. Select the button background and hit that ‘create’ button.

Step 3: You will then be taken to the Anima editor, where a new state of the button (this is where you specify what the hover state is) will be created for you. To build the minimal hover state prototype:

  1. Select the default/state1 button background layer
  2. A blue lightning bolt icon will be revealed. Click on that icon and connect the line to state2
  3. Choose the on ‘On Mouse Enter’ option. This is to set what interaction should trigger the state transition
  4. Select the state2 button background and adjust the opacity to 70% to set the hover style
  5. Repeat similar steps to connect the state2 button back to state1 ‘On Mouse Leave’
  6. Click on ‘Back to Sketch” on the very top left of your screen to exit the editor

Result: Back to the sketch interface, at the bottom right you should see the Anima section with a ‘Preview in Browser’ button. Click on that will spin up a preview browser tab that lets you play with the button hover state prototype.

Pros:

If you are designing with Sketch then the ability to prototype within the same environment is helpful.

Cons:

The prototyping features out of the box may not support exactly what you are trying to simulate. You’ll need to lean on third-party plugins, which has various complexity and learning curve.


Figma recently released more prototyping features that allow designers to build more advanced prototypes within the design environment. The new feature makes it fairly easy to build our example so let’s walk through that.

Step 1: Set up two frames with each button state design layers.

Step 2: With the default button background layer selected, toggle to the prototype tab located within the right panel.

Step 3: Click on the dropdown to select the ‘While Hovering’ option, second dropdown to ‘Swap with’, set the last dropdown to the name of your second frame.

Result: You should now see an arrow connecting the default button background to the second frame. Click on the present (play icon) located at the top right corner will allow you to play with the hover prototype.

Pros:

With the new Smart Animate feature, prototyping a hover interaction is fairly easy once you have the before and after states created.

Cons:

It lacks support for setting custom animation sequences. If you need to animate multiple items in the same interaction with various speed then that is currently not possible.


There are more tools out there to help with UX prototyping and there isn’t a perfect tool for every job. If you are serious about learning how to prototype well, finding the right tool(s) for the job is critical. Small exercises like the hover examples in this post can help you wrap your head around the strength and weaknesses of a tool.

Thanks for taking the time to go through each of the examples. Hopefully, you now have a high-level idea of how to use each of the tools mentioned and you will have some baseline knowledge when you need to choose a tool to prototype your designs in the future.

the-state-of-javascript-2019

We were pretty sure 2018 would be the last time we did this survey. After all, the JavaScript ecosystem can’t very well keep changing again, can it?

But what do you know, turns out JavaScript isn’t quite done changing just yet! And so after over 21,717 respondents took this year’s survey we had to dig up our components and charts, curse us-from-a-year-ago for writing such crappy code, and get to work digging through the data.

We had some help though. The amazing Amelia Wattenberger joined the team as a guest dataviz expert to contribute a fresh new look on our data, and you’ll be able to explore her work in the Overview section.

We also borrowed a couple new visualisations from the State of JS’s sister survey, the State of CSS. We recommend checking it out if you haven’t done so yet!

Team

The State of JavaScript Survey is created and maintained by:

Be sure to check out my React/GraphQL JavaScript framework, Vulcan.js, as well as Raphaël’s React data visualization library nivo.

Download Our Data

You can download the raw JSON data for this survey. Let us know if you end up making your own data visualizations!

Completion Percentages

Because all survey questions could be skipped, some questions ended up with fewer answers than others. So we’ve added a small pie chart indicator to each question to let you know which proportion of total respondents answered it.

Credits & Stuff

The site is set in IBM Plex Mono. Questions? Feedback? Get in touch!

And now, let’s see what JavaScript has been up to this year!

– Sacha and Raphaël

the-current-state-of-styling-selects-in-2019

Best I could tell from the last time I compiled the most wished-for features of CSS, styling form controls was a major ask. Top 5, I’d say. And of the native form elements that people want to style, Greg Whitworth has some data that the doesn’t do anything to the opened dropdown of items. (Screenshot from macOS Chrome)

Some browsers do let you style the inside, but it’s very limited. Any time I’ve gone down this road, I’ve had a bad time getting things cross-browser compliant.

Firefox letting me set the background of the dropdown and the color of a hovered option.

Greg’s data shows that only 14% (third place) of developers found styling the outside to be the most painful part of select elements. I’m gonna steal his chart because it’s absolutely fascinating:

Frustration % Count
Not being able to create a good user experience for searching within the list 27.43% 186
Not being able to style the 17.85% 121
Not being able to style the default state (dropdown arrow, etc.) 14.01% 95
Not being able to style the pop-up window on desktop (e.g. the border, drop shadows, etc.) 11.36% 77
Insertion of content beyond simple text in the 11.21% 76
Insertion of arbitrary HTML content in an 7.82% 53
Not being able to create distinctive unselected/placeholder style and behavior 3.39% 23
Being able to generate new options from a large dataset while the popup is open 3.10% 21
Not being able to style the currently selected 1.77% 12
Not being able to style the pop-up window on mobile 1.03% 7
Being able to have the options automatically repeat on scroll (i.e., if you have an list of options 1 – 100, as you reach 100 rather than having the user scroll back to the top, have 1 show up below 100) 1.03% 7

Boiled down, the most painful parts of styling selects are:

  • Search
  • Styling the open dropdown, including the individual options, including more than just text
  • Updating the element without closing it
  • Styling for cases where “nothing” is selected and when an item is selected

I’m surprised multi-select didn’t make the cut. Maybe it’s not on the table for control?!” It goes deep into all this.

complex-state-privacy-laws-hurt-all-of-us

To date, U.S. data privacy regulation has been bogged down with party politics. That’s because the debate has been about individual rights to privacy, versus data used for business gain. This political divide has stopped any federal regulation from being passed. Instead, states have stepped in, and Nevada, Vermont and California are among the many that have bills already passed or soon to pass.

The problem is that these state laws are not all the same. What started as an attempt to protect someone’s privacy is now becoming a big burden for the sites and companies that need to comply, and that’s an issue both sides of the debate should recognize.

A survey of small businesses from the Connected Commerce Council shows that 72% support better privacy regulations, but that 56% are concerned that they will negatively impact their business, and they’re right. The IAB promotes the use of a privacy compliance platform, but that new technology comes with costs in tech, time and labor and only succeeds if adoption of the platform is broad.

It’s time that our industry starts voicing the real problems that come with so many overlapping state privacy laws. Privacy for America is a good place to start. This non-profit is working to push a federal privacy agenda in Washington, and business can help increase the impact by supporting their approach. Individuals deserve good privacy regulation, but it should be created in a way that’s sustainable for business, too.


Opinions expressed in this article are those of the guest author and not necessarily Marketing Land. Staff authors are listed here.



About The Author

state-ags-prepare-to-announce-antitrust-investigation-against-google,-potentially-others

A forthcoming investigation involving more than 20 states attorneys general puts further legal pressure on Google and potentially other tech companies. Google is now being informally probed by the Justice Department, the Senate, and the House Antitrust Subcommittees. This is in addition to other investigations currently being conducted in Europe.

To a similar degree, Facebook, Apple and Amazon are also being investigated by Congress and the Federal Trade Commission or Justice Department for potential anti-competitive behavior.

‘A major escalation.’ Characterized as “a major escalation in U.S. regulators’ efforts to probe Silicon Valley’s largest companies,” the state attorneys general investigation was first reported by the Washington Post yesterday. However, it was widely expected based on earlier public statements and discussions. Reportedly, a formal announcement will come next week.

However, according to the Washington Post, it’s not yet clear whether Facebook or other companies might become part of the states’ investigation. CNN is separately reporting that it will focus on “Google advertising practices.” Not much detail is available beyond that, except for vague statements about Google “dominating” online advertising.

According to recent eMarketer data, however, Google’s share of online advertising this year will be down slightly, to just over 37%. Facebook will capture 22% of U.S. digital ad revenue, while Amazon is taking some share from both according to the firm.

States don’t have as much power as feds. States have the power to fine companies for the violation of their laws (e.g., consumer protection) and the ability to ask for policy changes, but they don’t have the same power as federal regulators to seek the break-up of companies or the “unraveling” of acquisitions. As a practical matter, the action by the states adds more pressure and cost for the tech giant(s) and could indirectly impact the scope or depth of the federal investigations.

The states were involved in the Microsoft antitrust case in the 1990s, although they didn’t lead it.

It’s important to note that these various investigations could go on for several years, with little or no change in the interim — except that Google and Facebook are less likely to make significant acquisitions. In addition, a change in the political leadership in Washington after 2020 could also impact these investigations, although they have bi-partisan support.

Why we should care. In 2013, the FTC closed its antitrust investigation of Google, declaring, “The law protects competition, not competitors.” Since that time the European Commission has fined Google more than $9 billion in three separate antitrust cases, which Google is appealing.

Facebook was recently fined $5 billion for data and privacy violations by the FTC. However, these fines have had limited impact and the market hasn’t punished either company. Accordingly, regulators and legislators may be looking for policy changes or more structural changes in addition to any potential fines. Indeed fines, regardless of their size, are likely to be seen as ineffectual.

Yet, what happened with Microsoft may be predictive of the future for Google and others. The company was determined to be a monopoly in April of 2000 and directed to be split into two halves. That never happened.



About The Author

Twitter or find him on LinkedIn.




what-location-data-can-tell-us-about-the-state-of-starbucks’-pumpkin-spice-latte

Even though Autumn doesn’t officially start until September 23, Labor Day marks the effective start of the season for most people. School is back in session, the weather starts to turn (a bit) and the much-loved but equally derided pumpkin spice latte (PSL) makes its return.

Been around now for 15 years. The flavored coffee drink was initially introduced by Starbucks in 2003 and has now been in the market for 15 years. It has almost single-handedly inspired an entire sub-genre of seasonal foods.

store visitation appears to waning.

Pumpkin-spice fatigue? According to a foot traffic analysis by location intelligence company Gravy Analytics, the venerable yet caloric drink didn’t drive additional any incremental visits when it was re-introduced in 2018. Gravy observed, “Average daily foot traffic decreased by 2%. Starbucks customers also didn’t visit their local Starbucks more frequently once the pumpkin spice latte was released. Average daily visits per device remained flat throughout the period.”

It’s not clear whether the public has become indifferent to the Starbucks drink in particular or whether there’s growing pumpkin-spice fatigue (PSF) more generally. Based on Starbucks’ foot traffic data, Gravy speculates that competing chains, such as Dunkin, may not reap rewards they anticipate from their own pumpkin spice drinks.

Starbucks Foot Traffic by Day of Week (Jul 15 – Oct 13, 2018)

showed that the introduction of the meatless Impossible Burger drove a nearly 20% increase in visitation to participating Burger King stores in test markets. This (and sales data) prompted the chain to introduce the faux burger nationally last month.

Why we should care. Location data has many uses. Audience segmentation and offline attribution are the most common. Competitive insights are gaining currency as well. But another important use case is product testing. Location data can be used a tool to determine the impact of a fast-food menu item, in this case, on store visits before the broader introduction of the product.

The pumpkin-spice latte is a lighthearted example to prove a larger point about the utility of location data to provide customer insights. And while test marketing and sales data have historically been used to determine product viability, location data can help assess whether that product still has market appeal — or has run its course.



About The Author

Twitter or find him on LinkedIn.




piling-on:-state-ags-intend-to-launch-their-own-antitrust-investigation-against-tech-biggies

A coalition of about 12 state attorneys general is getting ready to launch an antitrust investigation of U.S. tech giants, the Wall Street Journal reported Monday. The specific companies were not identified in the report, but they are likely Google, Facebook, Amazon and possibly Apple. 

This would be a separate inquiry from the current federal and Congressional investigations going on. According to the report the focus will be whether “a handful of dominant tech platforms use their marketplace powers to stifle competition.”

Bi-partisan state effort. The group is reportedly bi-partisan and probably includes Texas, North Carolina and Mississippi, among others. A formal announcement is expected next month. It’s not clear whether the federal and state investigations, assuming the latter goes forward, would be coordinated in any way or independent. 

Previously the Department of Justice (DOJ) and Federal Trade Commission (FTC) reached agreement on antitrust investigations of the four companies, with the DOJ pursuing Google and Apple and the FTC taking jurisdiction over Amazon and Facebook. 

Breakup on the table. And last week, FTC Chairman Joe Simon said that the government would consider breaking up companies “to restore competition,” although that was not the FTC’s immediate or preferred approach. Specifically, the government might “unwind acquisitions” made by one or more of the companies.

Facebook is seeking to more closely integrate its flagship app, Instagram and WhatsApp. One explanation is to create a unified platform for marketers. However, some critics see an attempt to pre-empt any potential breakup of the company. Indeed, the FTC acknowledged that operationally merged companies are much harder to break up. 

Outcomes unpredictable. The outcome of these various active and emerging investigations is not at all clear. It could and will likely be years before any resolution. And any decision by the government to break up one or more of the companies — the potential remedies could be very different by company — would be litigated in court. 

In 1999, Microsoft was formally determined to be an abusive monopoly by Judge Thomas Penfield Jackson. Jackson also recommended the company be split in two: one company for Windows OS and the other for everything else.

The split never happened, in part because Jackson’s remedy was rejected on appeal and partly because the incoming Bush administration had a very different perspective on competition and the market. In 2001 Microsoft settled with the DOJ, leaving the company intact.

As with Microsoft the 2020 election could also have an impact on any active antitrust investigations, though that’s now harder to predict than in 2000. All of the targeted companies have issued statements arguing they face a strongly competitive market and that they contribute to the economy. 

A taxing situation. On another front, U.S. tech companies now face a 3% tax on revenues generated in France. This applies to companies making more than 25 million euros in France and more than 750 million globally. This would include all the major technology companies. The tax was approved in July. Beyond the immediate concern over the tax itself, it’s possible that more countries could follow France’s lead, seeing U.S. technology firms as a source of new revenues.

Why we should care. Even though a resolution is probably years away, these investigations could result in structural changes to the U.S. digital market. Alternatively, nothing much might change. That was the case with the original FTC antitrust investigation of Google, which closed after Google agreed to modest changes to some of its practices.

The antitrust framework that U.S. regulators have used to determine whether to approve acquisitions or mergers is an evaluation of potential “consumer harm.” In that context, most of the big tech companies have convincingly argued that they are delivering convenience or lower cost to consumers.

The Europeans have been less persuaded by these arguments. And there are some indications that U.S. antitrust law and theory may be in flux. 



About The Author

Screenwerk, about connecting the dots between digital media and real-world consumer behavior. He is also VP of Strategy and Insights for the Local Search Association. Follow him on Twitter or find him at Google .




the-confusing-state-of-toggle-switches

Toggle switches on electrical devices are intuitive to use, but not so much on interfaces. Users often have trouble discerning whether they indicate a status or command. If the switch is “on,” users could interpret it as the current state, or as the action that occurs when they toggle it.

Status Signals

It’s not always clear to users that toggle switches signify the current state. This confusion happens when there are on/off labels, green/red colors, or checkmarks on them. These cues produce high visual noise that weakens status communication. Without a clear “on” signal, users fail to perceive the switches as indicators of state.

toggle-switch-signals

When communicating status, you only need to signify what’s active, not what’s inactive. Using cues to indicate both the active and inactive state makes users interact with switches like commands. Users have a habit of perceiving visual cues as indicators of action. When they see them on switches, they think it’s informing them what the control will do instead of what it’s currently doing.

To prevent users from misinterpreting your switches, you must reduce the visual noise on them and only provide a cue for the “on” state. The “off” state of your switches should have a neutral color, so it doesn’t steal attention. Adding any cues to the “off” state would produce noise that drowns out the signal. Avoid using “on/off” labels because they make the switches look like command buttons. Also, avoid using checkmarks, so users don’t confuse them with checkboxes.

The only cue the “on” state needs is a high-contrast color with the power symbol on the thumb of the switch. Users will recognize the state by not only color but also the distinct shape. The power symbol is the ideal icon for toggle switches because it’s the universal standard to communicate on/off states independent of language. This cue makes your switches accessible to both international and color-blind users.

Interaction Consistency

Another confusing aspect of toggle switches is the inconsistency between its form and interaction. The switch has the appearance of a slider, but most users don’t drag it. They press the switch like a button to activate it. Not only that, but some switches aren’t even draggable. When users do try to drag it, it doesn’t work as expected.

toggle-switch-interactions

The reason switches mimic toggle switches in the real-world is to help users interact with them without any knowledge of interfaces. But this skeuomorphic style isn’t useful if there isn’t a match between the computer interaction and physical interaction.

One potential solution is to lose the skeuomorphic metaphor and use a toggle button with the power symbol. The prominent icon would make the “on” signal more clear. Pressing it would activate and deactivate it as users would expect. This approach has potential, but it isn’t a familiar convention yet. If designers adopt it, users would see more toggle switches that work the way they appear.

Like a Light Switch

There’s a lot of confusion with toggle switches. But when you design them correctly, they become as intuitive as electrical switches. Remember that toggle switches should work like light switches.

How much visual noise is on a typical light switch? How many states do light switches have? Does a light switch show the current status or command? When you think about these questions, you’ll have no doubt how a toggle switch is supposed to look.

FP-tout

PP-tout