Connecting Angular and the WordPress API with wp-api-angular

Original Source: https://www.sitepoint.com/angular-wordpress-wp-api-angular/

In this tutorial, you’ll learn how to work with the wp-api-angular library that allows you to interact with the WordPress API from Angular 2+ applications. This library supports all major WP resources including users, posts, comments, media, taxonomies etc. It’s also quite simple to use, so you’ll get the idea in no time.

To see the library in action, we’re going to code the following features:

Authentication using JWT
Listing the users
Listing the posts
Creating and editing the posts
Deleting the posts

By the end of the article, you’ll become familiar with this library and will be ready to use it on your own.

The source code for this tutorial is available on GitHub.

I’ll assume you’re using Angular 5, but all explained concepts should be valid for Angular 2 as well.

Laying Foundations
Setting Up WordPress

Before we proceed to writing the code, there are a couple of things to take care of. First of all, note that the API we’re going to utilize works only with the self-hosted version of WordPress. For the web version (which can be configured via the WordPress site), there’s a separate API that has many similar concepts, though it’s still quite different.

You also have to enable permalinks — which is required for the API client to work correctly. For Nginx, you’ll need to add the following line to the nginx.conf file:

try_files $uri $uri/ /index.php?$args;

More detailed information and explanations on how to enable permalinks can be found in this WordPress Codex guide.

Lastly, we should take care of WordPress security which, as they say, is above all. For that, a special plugin called JWT Authentication is required. We’re going to use it in order to authenticate our API client with the help of special tokens (an approach that’s quite common these days).

That’s pretty much it. If you’d like to learn more about the WordPress API in general, skim through this article. When you’re ready, proceed to the next step and let’s see the Angular WordPress client in action!

Bootstrapping an Angular Application

Now that we have WordPress prepared, create a new Angular application by running:

ng new wp-api

This is going to create a skeleton for the application. We’re not going to discuss its structure thoroughly, but you may find more information in our Angular series.

Next, cd into the directory and install the library itself:

cd wp-api
npm install -g typings
npm install wp-api-angular –save

Now we need to import the proper components inside the src/app/app.module.ts file:

// … other imports
import { Http } from ‘@angular/http’;
import { HttpClientModule, HttpClient } from ‘@angular/common/http’;
import {
WpApiModule,
WpApiLoader,
WpApiStaticLoader
} from ‘wp-api-angular’;

WpApiModule should also be added to the imports block. Note that we must use an exported factory for AoT compilation or Ionic:

// … imports

@NgModule({
declarations: [
// … omitted
],
imports: [
BrowserModule,
FormsModule,
HttpClientModule, // <—
WpApiModule.forRoot({ // <—
provide: WpApiLoader,
useFactory: (WpApiLoaderFactory),
deps: [Http]
})

]
// …
})

Here’s the factory itself:

export function WpApiLoaderFactory(http: Http) {
return new WpApiStaticLoader(http, ‘http://YOUR_DOMAIN_HERE/wp-json/wp/v2/’, ”);
}

Don’t forget to provide your own domain name here!

Lastly, let’s also add some imports to the app.components.ts file:

import { Component } from ‘@angular/core’;
import { Observable } from ‘rxjs’;
import { NgForm } from ‘@angular/forms’;
import { HttpClientModule, HttpClient } from ‘@angular/common/http’;
import { Headers } from ‘@angular/http’;

// …

We’ll need NgForm to craft forms, HTTP modules to interact with the API and Headers to authenticate the client.

The initial setup is done and we can proceed to the next section.

Authentication

Before interacting with the API, we need to introduce an authentication mechanism. As I already mentioned above, a token-based authentication will be employed, so let’s add a token variable to the app.components.ts:

export class AppComponent {
token = null;
// …
}

Also, tweak the app.component.html file by adding a new block:

<div>
<app-authentication [(token)]=’token’></app-authentication>
</div>

In order for this to work, a separate component is required so generate it now:

ng generate component authentication

Import the necessary modules inside the src/app/authentication/authentication.component.ts file:

import { Component, OnInit, Input, Output, EventEmitter } from ‘@angular/core’;
import { HttpClientModule, HttpClient } from ‘@angular/common/http’;
// …

The authentication process is going to be very simple: a user should enter their login and password, submit the form, and a special token will be returned if the credentials are correct. This token will then be utilized to perform API requests. Therefore, let’s draft a user and add input and ouput for the AuthenticationComponent:

// …
export class AuthenticationComponent implements OnInit {
user = {
login: ”,
password: ”
}
@Input() token;
@Output() tokenChange = new EventEmitter<string>();

// …
}

Of course, you may define the user as a model, but for the purposes of this demo it’s not mandatory. As for the constructor, pass the HttpClient to it:

// …
constructor( private http: HttpClient ) { }

Next code the auth method. It’s as simple as sending a POST request to the proper URL with the credentials and waiting for the response:

// …
auth() {
this.http.post(‘http://YOUR_DOMAIN/wp-json/jwt-auth/v1/token’, {
username: this.user.login,
password: this.user.password
}).subscribe((data) => {
if (data[‘token’]) { // if token is returned
this.token = data[‘token’];
this.tokenChange.emit(this.token);
}
});
}

Once again, don’t forget to insert your domain name into the URL.

The component is ready, and the last thing to do in this section is create the corresponding form. It should be displayed only if the token is null. When the form is submitted, the auth method should be called:

<form *ngIf=’token == null’ (ngSubmit)=’auth()’>
</form>

Flesh the form out by adding two fields and a Submit button:

<form *ngIf=’token == null’ (ngSubmit)=’auth()’>
<div class=’form-group’>
<label for=’login’>Login</label>
<input type=’text’ class=’form-control’ [(ngModel)]=’user.login’ name=’login’ id=’login’ required>
</div>

<div class=’form-group’>
<label for=’password’>Password</label>
<input type=’password’ class=’form-control’ [(ngModel)]=’user.password’ name=’password’ id=’password’ required>
</div>

<button type=”submit” class=”btn btn-success”>Submit</button>
</form>

That’s it! The authentication feature is finished, and we may start playing with the API itself.

Continue reading %Connecting Angular and the WordPress API with wp-api-angular%

Get 15% off Adobe Creative Cloud with our exclusive deal

Original Source: http://feedproxy.google.com/~r/CreativeBloq/~3/LtTD_FZGqGI/get-15-off-adobe-creative-cloud-with-our-exclusive-deal

When it comes to finding Adobe deals, discounts on Creative Cloud can be few and far between. But great news for designers, illustrators and artists: we’ve teamed up with Adobe to offer Creative Bloq readers a special 15% discount on Creative Cloud membership. Instead of paying the usual US$49.94/£49.94 every month, you’ll pay just $42.46/£42.46 for the first year.

So if you’ve been debating whether to sign up, now’s your chance to get hands-on with Adobe’s stellar suite of world-class design tools – and save some cash in the process.

The offer is valid from now until 13 May 2018, and includes Adobe’s entire suite of desktop and mobile apps for Mac and PC, from essentials such as Photoshop CC to next generation tools such as Adobe XD CC.

Save 15% on Adobe Creative Cloud now

Adobe Creative Cloud subscribers get full access to over 20 premium creative apps, including:

Photoshop for editing still and motion graphicsLightroom for Cloud-based photo editingLightroom Classic for desktop-focused photo editingIllustrator for vector illustrationInDesign for publishing designDimension (previously Project Felix) for photorealistic 3D images Adobe XD for designing and prototyping websites and appsPremiere Pro for timeline-based video editingAfter Effects for video post productionDreamweaver for web design and developmentAcrobat Pro for creating, editing and signing PDFsIllustrator Draw for vector drawing anywhereAdobe Spark for creating graphics, web pages and video stories in minutesBridge for centralising your creative assets And a lot more…

As you’ll know, these programs are fully integrated, meaning you can work between them (and devices) seamlessly – whether you’re out and about or in the studio.

Built-in templates help you jump-start your designs, while step-by-step tutorials will help you sharpen your skills and get up to speed quickly.

Save 15% on Adobe Creative Cloud now

Your Creative Cloud subscription also gives you 20GB cloud storage allowance, making it easier than ever to create across multiple devices and collaborate by sharing files with others.

This special deal is a limited offer, though – it expires on 13 May, so don't miss out.

Related articles:

The 17 best Adobe Illustrator plugins7 insane tech sneaks from Adobe Max 2017Behind the scenes on Adobe and Coca-Cola's design challenge

ES6 in Action: let and const

Original Source: https://www.sitepoint.com/es6-let-const/

In this tutorial, I’ll introduce let and const, two new keywords added to JavaScript with the arrival of ES6. They enhance JavaScript by providing a way to define block-scope variables and constants.

This article is one of many covering new features of JavaScript introduced with ES6, including Map and WeakMap, Set and WeakSet, new methods available for String, Number, and Array, and the new syntax available for functions.

let

Up to ES5, JavaScript had only two types of scope, function scope and global scope. This caused a lot of frustration and unexpected behaviors for developers coming from other languages such as C, C++ or Java. JavaScript lacked block scope, meaning that a variable is only accessible within the block in which it’s defined. A block is everything inside an opening and closing curly bracket. Let’s take a look at the following example:

function foo() {
var par = 1;
if (par >= 0) {
var bar = 2;
console.log(par); // prints 1
console.log(bar); // prints 2
}
console.log(par); // prints 1
console.log(bar); // prints 2
}
foo();

After running this code, you’ll see the following output in the console:

1
2
1
2

What most developers coming from the languages mentioned above would expect, is that outside the if block you can’t access the bar variable. For example, running the equivalent code in C results in the error ‘bar’ undeclared at line … which refers to the use of bar outside the if.

This situation changed in ES6 with the availability of block scope. The ECMA organization members knew that they could not change the behavior of the keyword var, as that would break backward compatibility. So they decided to introduce a new keyword called let. The latter can be used to define variables limiting their scope to the block in which they are declared. In addition, unlike var, variables declared using let aren’t hoisted. If you reference a variable in a block before the let declaration for that variable is encountered, this results in a ReferenceError. But what does this mean in practice? Is it only good for newbies? Not at all!

To explain you why you’ll love let, consider the following code taken from my article 5 More JavaScript Interview Exercises:

var nodes = document.getElementsByTagName(‘button’);
for (var i = 0; i < nodes.length; i++) {
nodes[i].addEventListener(‘click’, function() {
console.log(‘You clicked element #’ + i);
});
}

Here you can recognize a well-known issue that comes from variable declaration, their scope, and event handlers. If you don’t know what I’m talking about, go check the article I mentioned and than come back.

Thanks to ES6, we can easily solve this issue by declaring the i variable in the for loop using let:

var nodes = document.getElementsByTagName(‘button’);
for (let i = 0; i < nodes.length; i++) {
nodes[i].addEventListener(‘click’, function() {
console.log(‘You clicked element #’ + i);
});
}

The let statement is supported in Node and all modern browsers. There are, however, a couple of gotchas in Internet Explorer 11 which you can read about in the ES6 compatability table.

A live demo that shows the difference between var and let is shown below and is also available at JSBin:

ES6 in Action: let and const on jsbin.com

Continue reading %ES6 in Action: let and const%

22 free ebooks for designers and artists

Original Source: http://feedproxy.google.com/~r/CreativeBloq/~3/vVj1XPqFvx0/free-ebooks-designers-7133700

There's always been a healthy market for commercial graphic design books, illustration books and student books written by experts, and this isn't likely to change any time soon. Sometimes there's just no substitute for splashing your cash and getting high quality content in return. 

That said, there's a growing movement towards free and 'freemium' content on the web. And the quality of the content is often on a par with the books you'd part with cash for.

Clearly nobody can afford to print and distribute free physical books (with the exception of the excellent World Book Night movement). But in this age of tablets, smartphones and laptops the electronic book offers a fantastic, and very cheap, way to spread this content.

So with all that in mind, what content can you get for free in the field of design? A quick search on your favourite search engine will reveal hundreds of offerings, making it difficult to sift the wheat from the chaff. But we've saved you the trouble, so here goes…

01. The Shape of Design

Frank Chimero’s book will inspire you to look at what you do in a whole new light

Starting life as a talk in 2010, Frank Chimero's self-published The Shape of Design was an early design community Kickstarter success, getting funded on its first day, and has since become essential foundational reading, not just in design education but in other creative practices, too. 

Focusing on the mindset of making rather than tools and methods, it asks: what are the opportunities, problems and possibilities of the creative practice? And once the work is done, what happens when it is released into the world?

02. The DesignBetter.co library

These three books cover product design, design thinking and design leadership

Why settle for just one free ebook when you can have three? The DesignBetter.co library from InVision aims to help you build a strong design practice. 

This collection of definitive books, written by Aarron Walter and Eli Woolery, explores how the best companies approach product design, design thinking, design leadership and more.

03. Practical Responsive Typography

Nail your web typography with this free in-depth volume

Getting your typography right is a key part of having a great-looking website that helps you stand out from the crowd, communicate with clarity, and cultivate a distinctive identity. The best way to learn is to roll up your sleeves and just get on with it, and this book by Dario Calonaci enables you to do just that. 

Practical Responsive Typography will take you from the basics of scaling and optimising screen spaces, through to using a range of different web fonts and customising typography designs to suit your identity, and while it'll normally cost you over £20, it's free for Creative Bloq readers.

04. 50 Must Read Tips From Designers, To Designers

Experienced designers share their tips

As the title suggests, this free ebook from Route One Print brings together key pieces of advice from experienced graphic designers – including Jacob Cass (aka Just Creative) and Brent Galloway – to make your life easier. "From client management to typography, brand identity to finding alternative textures in Photoshop, this ebook offers practical tips for designers and showcases new ways to think about design," says the blurb. 

It also promises to reveal which fonts the designers never use. Is it Comic Sans? Helvetica? We guess you'll have to download it to find out. Route 1 offers a whole range of ebooks for designers in fact, including The Freelancer’s Bible (below) and The Design Comedy: How to deal with the 9 stages of client hell.

05. Brand House Book

The Brand House Book breaks branding down into six manageable stages

If you're having problems getting to grips with the world of branding, this free ebook by Roger Lindeback can help you out by taking away all the jargon and relating it to everyday experience.

In the Brand House Book, Lindeback aims to make branding tangible by comparing it to building a house, breaking it down into six manageable stages – dreaming, planning, starting work, designing, building and finally getting the details right – with a branding summary at the end of each stage, setting out all the important issues to think through in your brand building process.

06. The Practical Interaction Design Bundle

Get three helpings of interaction design advice for the price of none

Not one but three free ebooks in one handy bundle, The Practical Interaction Design Bundle consists of three free volumes from UXPin, comprising over 250 pages of design best practices and with over 60 examples of the best UX design. 

Volumes 1 and 2 of Interaction Design Best Practices will take you through techniques, theories and best practices relating to the tangibles of interaction design – words, visuals and space – while volume 2 tackles the intangibles: time, responsiveness and behaviour. 

Topping off the bundle is Consistency in UI Design, covering how and when to maintain consistency in your design, and when to break it to draw attention to elements without suffering the drawbacks.

07. An Introduction to Adobe Photoshop

What’s a Photoshop? This book will tell you

If you're after a beginner-friendly guide to getting started with Photoshop, this free ebook by Steve Bark will explain the fundamentals for you, from panels and tools to layers and basic printing.

If it's just a little too basic for you, never fear; there's also an intermediate guide available that covers more advanced subjects such as vector tools, smart objects and clipping masks.

08. The Building Blocks of Visual Hierarchy

Learn to create accessible, intuitive layouts

If you're designing for the web and want your layouts and interfaces to be accessible and visually intuitive, this free ebook from UXPin is an invaluable resource. 

It explains how size, colours, space, layout, and style affect visual understanding, provides tips for designing clear visual hierarchies, and includes 18 examples of great sites including MailChimp and RelateIQ.

09. The Freelancer's Bible

From marketing to tax, plan out your freelance career with this book

Whether you're already freelance or thinking of making the jump, this ebook from Route One Print is full of useful freelance advice, with tips on how to market your business, find your USP, licence your work, manage client relationships, complete tax returns and much more.

10. Flat Design & Colors

free ebooks

Love flat design but don’t know where to start? Download this freebie

The free ebook Flat Design & Colors by UXPin dives deep into the most powerful techniques for creating highly usable yet visually interesting web designs. 

The design team compiled advice from experts and illustrated their points using examples from 40 companies such as Google, Squarespace, and others.

11. Houdini Foundations

Add that extra dimension to your designs with this free ebook on Houdini 

If you're looking to add a touch of 3D art to your designs, this free ebook on Houdini will help get you started. Learn all about the tools and techniques you will use as a Houdini artists then run through three lessons that teach you how to build simple projects from scratch. 

12. The Future of Product Design

free ebooks for designers

Learn the ins-and-outs of product design with this immersive ebook

In this report, Jonathan Follett from Invo examines from a designer's perspective the ways emerging technologies are affecting the product lifecycle, and explores various options for companies looking at new ways of approaching product design and development. 

Even if you're not specifically in the business of product design, this freebie is an eye-opener.

13. Everything There is to Know About Logo Design

free e-books for designers

This handbook to logo design gives you a quick and thorough introduction

Whether you're new to logo design or just want to swat up on some tips and tricks, the Everything There is to Know About Logo Design ebook is a great little guide to get you going.

In this 25-page guide, you’ll learn the basics of what a logo is, rules for creating a logo and other things to consider, such as colours and typography.

14. Design's Iron Fist

free e-books for designers

This free ebook will help you get the best out of yourself

Jarrod Drysdale is a designer writer who focuses his articles on getting the best out of your work. This is a sort of continuation of his previous book Bootstrapping Design (now discontinued), in which he collects all of his previous essays into one, free ebook. 

Topics such as 'Think like a designer' and 'Get out of a creative rut' are just some of the titles on offer in this selection.

15. Pixel Perfect Precision Handbook

free ebooks for designers

The Pixel Perfect Precision ebook has had an important update

The Pixel Perfect Precision (PPP) Handbook from leading digital design agency ustwo has come a long way since it was first released. What started as a 108-page simple guide to best practice with pixels and Photoshop has grown into handbook number 3 – a whopping 214-page designer bible.

16. The Creative Aid Handbook

free ebooks for designers

The Creative Aid book aims to be a mini resource for your creative projects

Created by Kooroo Kooroo, The Creative Aid is a free book jam packed full of inspiration and available to download today.

Co-founders Nicole Smith and Richard Tapp explain the concept: "It's a mini resource for your creative projects and food for your creative thoughts. We’ve included our own valuable references and resources we know and trust as a means to help you get your projects done. 

"We want to give you the creative push from a direction you may not have thought of, be it informative, inspirational, or simply entertaining."

17. The Vignelli Canon

Learn from one of the greats of design, Massimo Vignelli

Iconic designer Massimo Vignelli didn't just like to create good design: he was also passionate about sharing its principles, rules and criteria so others could do the same. 

His landmark book The Vignelli Canon uses numerous examples to convey applications in practice from product design via signaletics and graphic design to corporate design. And best of all, in 2009 he made it available for free as a PDF.

18. Type Classification eBook

Grasp the fundamentals of type selection

This excellent 27-page ebook details the 10 key classifications for typography, providing the basic understanding you'll need to gain a grasp of the fundamentals of type selection. The book covers a brief history for each of the classifications, as well as the core characteristics of the style.

19. Creative Suite Printing Guide

Wave goodbye to bad printing by following this guide

This handy book from Adobe provides all the information you'll need to get the best-quality results possible when printing from Adobe Photoshop, Illustrator, InDesign and Acrobat.

Over the course of 149 pages the different tools and options within each package are broken down, illustrating how to produce files for print that will provide accurate colour reproduction, pixel-perfect transparency matting and sharp lines.

20. Breaking the Time Barrier

Time is money, and this helpful tome won’t take up too much of it

This ebook tells a parable, using a semi-fictional scenario to illustrate the importance of pricing your work at the right level. The book itself will take an hour or two to read, and really focuses only one core message, but it’s a valuable lesson for designers starting out in business for themselves.

21. Graphic Design for Non-profit Organizations

free ebooks for web designers: Graphic Design for Non-profit Organisations

Graphic Design for Non-profit Organisations

The book focuses mainly on design and best prac­tices for non-profit orga­ni­za­tions, but the con­tent is a great resource in gen­eral and the teach­ings can be applied pretty much any­where.

22. The Design Funnel

Learn to turn client input into something that’s actually useful

Another manifesto from the ChangeThis.com website, this offering from author Stephen Hay provides a methodology for converting client input (which may often be extremely vague!) into a meaningful design approach. As with Hugh MacLeod's book, this free PDF offers a personal insight into the process, demonstrating its value.

Related articles:

5 must-read books for design studentsHow to design a book in InDesign9 indie mags you should read

10 Free Wireframe Kits To Speed Up Your Design Workflow

Original Source: http://feedproxy.google.com/~r/1stwebdesigner/~3/X_vQY4hr7mw/

The wireframing process is crucial to every new UI project. Before you get into the colors and typography you have to consider the user experience first. And this all starts with great wireframing.

Many designers prefer working on paper, but wireframing kits let you work digitally too. I’ve curated the best wireframing UI kits on the web that you can download for free and reuse for all mobile and web interface projects.

Jolly UI

jolly ui

The Jolly UI kit offers both a free and premium resource for designers. It’s the best hand-drawn wireframing kit you’ll find with an extensive collection of navigation menus, sliders, buttons, and common page elements.

If you just need something basic to get you started then grab the free version. It comes in both PSD and AI formats and all the elements are full vectors.

Basic Wireframe Kit

dark wireframe kit

Wireframing should be a very simple process. Black and white works best and that’s why this Basic Wireframe Kit is a great choice for Sketch users.

All the elements are rigidly designed, and they blend nicely into any type and style of website. It’s also one of the simpler UI kits for Sketch, so it’s a must-have resource for anyone moving away from Adobe software.

Teracy

teracy uikit

For a more complete collection of Sketch elements take a look at the Teracy Wireframe Kit.

This completely free Sketch asset offers dozens of common UI elements including dropdowns, input fields, breadcrumbs, and slideshow widgets. Teracy focuses more on website elements, but it also has plenty of mobile app elements too.

Blue Wireframes

blue ui wireframes

Some designers look at wireframes as blueprints for the entire project. That’s why this blue wireframing kit is a great choice both for aesthetics and practicality.

It’s another Sketch UI kit, and it’s free to use for all projects. The unique design of each element brings some pizzazz into your wireframing. And since all of the elements are vectors you can resize them with no quality loss.

Savvy Sketch iOS Wireframe Kit

savvy wireframing kit

Mobile apps need to be wireframed just like websites and the Savvy Sketch iOS Kit is perfect for iPhone app designers.

This UI kit is frequently updated with new features, with the latest release focusing on iOS 10. It’s completely free to use, and this UI kit is accurate which makes it easy to convert wireframes into full applications.

Basiliq

basiliq wireframe kit

Wireframing is popularly done on paper but it can be easier when done digitally. That’s why UI kits like Basiliq bring the best of both worlds.

You get a fully digital UI kit for Photoshop where all the elements look like sketched-out items on paper.

This kit works best with website mockups so if you’re building a website in Photoshop consider grabbing a copy of this kit before getting into the details.

Responsive Wireframes

wireframing design lofi

What I like most about these wireframe elements is their simplicity. True low-fidelity wireframes show you how the UI should look & behave without giving any specifics.

The PSD file is available for free on Dropbox. It’s a fun wireframing kit for any project and it relies on very simple shapes for common page elements.

BeTheme Free UI Kit

betheme ui kit

BeTheme is a full-scale premium WordPress theme created by a team called MuffinGroup. But they released a free wireframing kit called BeTheme UI which is just as valuable to designers.

This is a high-fidelity kit that uses blue throughout. Still an excellent choice because of the sheer volume of items you get in the pack.

The Ultimate Wireframe UI Kit

ultimate wireframing kit

MediaLoot offers a bunch of premium items but they do have one freebie called The Ultimate Wireframe UI Kit.

Technically there is a premium license which has a no attribution clause for commercial use. However, most designers can get by using the free pack since it contains the same elements.

And based on the massive file size of this PSD, I think it deserves to be called the “ultimate” wireframing kit.

App Mockup UI

app mockup ui kit

Another freebie resource from a premium site is this app wireframing kit from Pixeden. Each screen comes in the size of a typical iPhone where you can rearrange the page elements at will.

Each item is a vector shape, super easy to resize and restyle.

If you’re designing for the iPhone or any iOS device, there’s no better resource to start with—especially if you like starting with low-fidelity wireframes.

Bootflat UI Kit

bootflat ui it

Named after the famous Bootstrap framework is this free Bootflat UI kit. It comes in one large PSD file and offers dozens of common website elements you can reuse over and over again.

Bootflat is colorful, well-designed, and intricate with many dynamic elements like dropdowns and pricing tables. This works well in both wireframing and final mockup designs. You might even pair this with another PSD wireframing kit to use this as the final high-fidelity mockup later in the design process.

But whether you’re a Photoshop lover, Illustrator user, or Sketch enthusiast, there’s a wireframing kit here for everyone.


14 Top Sci-Fi Designs to Inspire Your Next Interface

Original Source: https://www.sitepoint.com/14-top-sci-fi-designs-to-inspire-your-next-interface/

Interface design has been around for more than 50 years.


Image Credit

The first ever GUI was designed for the NLS computer collaboration system in late 1968. Since then the hardware has gotten more and more advanced, allowing us to make GUIs as awesome as they are today, or will be someday…

Do you remember this scene from the Matrix?

Or the terrific interfaces Tony Stark manipulates with his bare hands…

But even in the 60s and 70s people were dreaming of interfaces like those we have today, and they found their place in sci-fi movies like in “2001: A Space Odyssey” released in 1968.

Sci-fi movies are known to be a sort of a window into the future. Many of the fantastical technologies filmed only decades ago are already available, and can be found in our pockets or on our wrists.

Computer interfaces in sci-fi movies can be real masterpieces. Let’s look at some movies, and I’ll show you examples of interfaces you can use as an inspiration while designing another dashboard or website template.

Let’s begin.

BLIND

The first on my list is the design studio BLIND.

They’re known to be one of world’s top creative design studios with extensive expertise in UI design. They’ve created interfaces for movies that all of us have seen. Check them out:

Justice League

“People are so slow…” — I wonder how many years will pass until we get interfaces resembling these?



The Dark Knight Rises

When you’re a billionaire you can afford to have your own UX department, can’t you?

The Fifth Estate

Perhaps we’ll take a page from the typical hacker’s desktop in the future.


The Dark Knight

When you’re hunting criminals and are feeling tense 24/7, a green, soothing color scheme should definitely help you.



Doom

Even though the game Doom 4 was released almost 12 years after this movie, the interfaces look like the ones you can see in this movie.



Rogue One

The iconic interfaces in the Star Wars saga were really minimal. Maybe George Lucas was right and minimal interfaces are the future?

Continue reading %14 Top Sci-Fi Designs to Inspire Your Next Interface%

The Best Ways to Quickly Publish a Blog or Website

Original Source: https://inspiredm.com/the-best-ways-to-quickly-publish-a-blog-or-website/

Every business needs an online presence. A blog or a website is necessary, and it is preferable to have both at once. Social media is optional, although some would have you think otherwise.

The principle purpose of your social media, if you have it, should be to help boost the profile of your blog or website. The opposite is not true.

The importance of having a website or blog is so determinative in terms of reaching the full potential your business can achieve that it’s really not something you should delay implementing for too long.

Before you can sell or persuade, people need to be able to find you. The easiest way to get found is to have a website telling people who you are, where you are, what you have, and why they should do business with you.

You need that online presence established now. So what’s the best way to achieve that goal as quickly as possible? That’s the topic of this article.

First, have some idea of what you want to say

Far too often business owners rush to get their website online without actually having anything meaningful to say. As mentioned above, the minimum your website should contain is:

Who you are – the company name, and optionally the names behind the name
Where you are – the physical location of your business (city, at least)
What you have – description and images of the goods and services you offer
Why people should do business with you – there are thousands of other businesses competing with yours for attention. You must have some competitive advantage to help you stand out from others, and you’ll need to make it as obvious as you can.

illustration courtesy of deomis ?

Those are the bare minimums you should include on your website or blog, but you can certainly include more information. You can never have too much content on your site, you can only have too little.

But quantity of content is not what you’re really aiming for. Quality is the most important factor, and that is in terms of:

The usefulness of the information to your audience
The presentation of the information
The user experience (UX) factor

Should you fail on any of these criteria, the success of your site will suffer, and in turn the success of your business will be affected.

The golden rule of business websites is you should publish quickly, but never without a plan.

Site should be adapted to fit the content

Another common mistake many people make is to choose pre-made templates and then massage their content to fit the style of the template. This is a wrong approach for many reasons.

The main reason is because it limits what you can show, which will diminish the usefulness and presentation of the information (two of our main criteria listed above). The other reason is because your site risks being too generic. It won’t stand out because it lacks sufficient customization.

If you’re not great at coding and design, go ahead and use a generic template, but choose one that is very open and easy to modify later. A template that is too complex may look “impressive” but it will make it much more difficult for you to update your site in the future.

illustration courtesy of DAN Gartman

Keep your focus on the content

Everyone wants a good looking website, but that should not be your priority in the initial stages. Your priority should be to get your content online so Google can start indexing your content as soon as possible.

Once your content is published, you can go back in and add things to make it look more beautiful. Getting page rank is more important because Google is more likely to see your page before any humans do, and the robots from Google care more about things like quality content and accessibility than they do about aesthetics.

In fact, they’ll possibly rank you higher initially for a website that doesn’t have a lot of background design because the page will load that much faster. After genuinely improving the look of the site, it’s unlikely you will lose rank.

Getting attention from Google early is good for you because apparently Google keeps the rank of a new site artificially low for some time after it is created. Once your site has been online for sufficient time, Google allows it to rank naturally. For some reason, Google equates longevity with trust.

In general it takes around six months for Google to stop thinking of your site as a “new” site, and at that point you will normally see some improvement in your page rank as long as you haven’t ignored any other SEO factors that would be detrimental to your rank.

Choose an appropriate publishing technology

There are plenty of different ways to publish a website, but remember that our goal is to get our site online as quickly as possible. You don’t want to rush it too hastily and publish without a plan, but you also don’t want to be waiting weeks to get online because every day counts.

With it taking approximately six months to attain rank, every extra day is costing you potential business and page position. So let’s cut to the chase.

You need to choose a publishing platform that will allow you to get up and running in the fastest time. Currently the two leading contenders in this category are SquareSpace and WordPress.

Rather than going through all the details of comparing them here in this article, we’ll just link you to a comparison that already exists. Go check out this excellent side-by-side comparison of SquareSpace vs WordPress and then come back to read the rest of this article to find out what to do next.

illustration courtesy of Kevin Yang

Build the site

Now that you’ve chosen an appropriate technology to help you get your site online quickly, and you have a solid plan of what you’re going to create, it’s time to actually build it.

This doesn’t have to be your final website design. In fact, what you create at this stage may look nothing like your eventual website will look. The important thing is getting your content online and indexed by Google. All the beautification can be done at a later time.

You’ll simply begin adding your content in an appropriate way to the site template you’re using. Ideally we think it should be the simplest and least feature-rich template possible, so you can come back later and customize it heavily (and you’ll avoid that generic website look), but it’s fine if you find some awesome template that you can’t resist.

Just remember to make it sufficiently different to what everyone else using the same template has done, or you’ll look like you don’t care about creating a good site.

If you have skills to design and code the site yourself, go right ahead and do it. If you don’t have much confidence in your skills, consider hiring people to help you out

You’ll save time by getting help, so your site will be online faster. You’ll also have the chance to use the time you save to learn the skills you need to learn, which could be valuable in the future.

Test the site

Launching without testing is a fatal mistake. This doesn’t just mean opening it up in a browser and looking at it. You need to actually have somebody read the site and give you feedback. The more people who do this, the better.

Take notes at this stage, but don’t do anything with them. That’s for your redesign stage that comes after launching your site.

illustration courtesy of Anton Fritsler (kit8)

Launch the site

Congratulations, you are ready for your site to go live. Remember this is not your actual site that you’ll be keeping in perpetuity. It is your early version site that you’re just publishing as quickly as possible for a robot to read.

Once you’ve launched the site, the clock starts ticking on your first robot read, and the six month wait to get a proper Google rank begins reducing from that point forward. But this is no time to rest on your laurels.

Start your redesign immediately after launch

This is the time you will return to the feedback you received and start making improvements. You’ll update the design, add new content, fix and extend the navigation, create internal and high value external links, and you’ll do all this while following the best practices to avoid the wrath of Google from descending upon you.

The three reasons you waited until now to do the redesign include:

You need the content up quickly. That’s the priority every time, as long as the content itself is correct and not full of errors. Do spend some time to craft that, and also consider hiring a professional copywriter to create compelling content for you.
Google rewards you for updating your content, and the more regularly it’s updated, the better. The exception is if you update your content with duplicate content that was lifted from another site. That will have negative consequences.
You have plenty of time now to relax and do the job properly, crafting an incredibly good design with no pressure. You’ll get the best result and you can easily slide that clever background design and extra functionality in behind your existing content.

Publishing your website quickly is a great idea, and if you follow the advice above, you’ll get the best results while avoiding the common mistakes that lead to failure.

header image courtesy of Sean Farrell

The post The Best Ways to Quickly Publish a Blog or Website appeared first on Inspired Magazine.

The Rise Of Intelligent Conversational UI

Original Source: https://www.smashingmagazine.com/2018/04/rise-intelligent-conversational-ui/

The Rise Of Intelligent Conversational UI

The Rise Of Intelligent Conversational UI

Burke Holland

2018-04-05T13:00:48+02:00
2018-04-05T15:49:05+00:00

For a long time, we’ve thought of interfaces strictly in a visual sense: buttons, dropdown lists, sliders, carousels (please no more carousels). But now we are staring into a future composed not just of visual interfaces, but of conversational ones as well. Microsoft alone reports that three thousand new bots are built every week on their bot framework. Every. Week.

The importance of Conversational UI cannot be understated, even if some of us wish it wasn’t happening.

The most important advancement in Conversational UI has been Natural Language Processing (NLP). This is the field of computing that deals not with deciphering the exact words that a user said, but with parsing out of it their actual intent. If the bot is the interface, NLP is the brain. In this article, we’re going to take a look at why NLP is so important, and how you (yes, you!) can build your own.

Speech Recognition vs. NLP

Most people will be familiar with Amazon Echo, Cortana, Siri or Google Home, all of which have an interface that is primarily conversational. They are also all using NLP.

Large preview

Aside from these intelligent assistants, most Conversational UIs have nothing to do with voice at all. They are text driven. These are the bots we chat with in Slack, Facebook Messenger or over SMS. They deliver high quality gifs in our chats, watch our build processes and even manage our pull requests.

Getting workflow just right ain’t an easy task. So are proper estimates. Or alignment among different departments. That’s why we’ve set up ‘this-is-how-I-work’-sessions — with smart cookies sharing what works well for them. A part of the Smashing Membership, of course.

Explore features →

Smashing TV, with live sessions for professional designers and developers.

Large preview

Conversational UIs built on text are nice because there is no speech recognition component. The text is already parsed.

When it comes to a verbal interaction, the fundamental problem is not recognizing the speech. We’ve mostly got that one down.

OK, so maybe it’s not perfect. I still get voicemails every day like a game of Mad Libs that I never asked to play. iOS just sticks a blank line in whenever they don’t know what exactly was said.

Large preview

Google, on the other hand, just tries to guess. Like this one from my father. I have absolutely no idea what this message is actually trying to say other than “Be Safe” which honestly sounds like my mom, and not my dad. I have a hard time believing he ever said that. I don’t trust the computer.

Large preview

I’m picking on voice mail transcriptions here, which might be the hardest speech recognition to do given how degraded the audio quality is.

Nevertheless, speech recognition is largely a solved problem. It’s even built right into Chrome and it works remarkably well.

Large preview

After we solved the problem of speech recognition, we started to use it everywhere. That was unfortunate because speech recognition on it’s own doesn’t do us a whole lot of good. Interfaces that rely soley on speech recognition require the user to state things a precise way and they can only state the limited number of exact words or phrases that the interface knows about. This is not natural. This is not how a conversation works.

Without NLP, Conversational UI can be true nightmare.

Conversational UI Without NLP

We’re probably all familiar with automated phone menus. These are known as Interactive Voice Response systems — or IVRs for short. They are designed to take the place of the traditional operator and automatically transfer callers to the right place without having to talk to a human. On the surface, this seems like a good idea. In practice, it’s mostly just you waiting while a recorded voice reads out a list of menu items that “may have changed.”

Large preview

A 2011 study from New York University found that 83% of people feel IVR systems “provide either no benefit at all, or only a cost savings benefit to the company.” They also noted that IVR systems “score lower than any other service option.” People would literally rather do anything else than use an automated phone menu.

NLP has changed the IVR market rather significantly in the past few years. NLP can pick a user’s intent out of anything they say, so it’s better to just let them say it and then determine if you support the action.

Check out how AT&T does it.

AT&T has a truly intelligent Conversational UI. It uses NLP to let me just state my intent. Also, notice that I don’t have to know what to say. I can fumble all around and it still picks out my intent.

AT&T also uses information that it already has (my phone number) and then leverages text messaging to send me a link to a traditional visual UI, which is probably a much better UX for making a payment. NLP drives the whole experience here. Without it, the rest of the interaction would not be nearly as smooth.

NLP is powerful, but more importantly, it is also accessible to developers everywhere. You don’t have to know a thing about Machine Learning (ML) or Artificial Intelligence (AI) to use it. All you need to how to do is make an AJAX call. Even I can do that!

Building An NLP Interface

So much of Machine Learning still remains inaccessible to developers. Even the best YouTube videos on the subject quickly become hard to follow with subjects like Neural Networks and Gradient Descents. We have, however, made significant progress in the field of Language Processing, to the point that it’s accessible to developers of nearly any skill level.

Natural Language Processing differs based on the service, but the overall idea is that the user has an intent, and that intent contains entities. That means exactly nothing to you at the moment, so let’s work up a hypothetical Home Automation bot and see how this works.

The Home Automation Example

In the field of Natural Language Processing, the canonical “Hello World” is usually a Home Automation demo. This is because it helps to clearly demonstrate the fundamental concepts of NLP without overloading your brain.

A Home Automation Bot is a service that can control hypothetical lights in a hypothetical house. For instance, we might want to say “Turn on the kitchen lights”. That is our intent. If we said “Hello”, we are clearly expressing a different intent. Inside of that intent, there are two pieces of information that we need to complete the action:

The ‘Location’ of the light (kitchen)
The desired state of the lights ‘Power’ (on/off)

These (Location, Power) are known as entities.

When we are finished designing our NLP interface, we are going to be able to call an HTTP endpoint and pass it our intent: “Turn on the kitchen lights.” That endpoint will return to us the intent (Control Lights) and two objects representing our entities: Location and Power. We can then pass those into a function which actually controls our lights…

function controlLights(location, power) {
console.log(`Turning ${power} the ${location} lights`);

// TODO: Call an imaginary endpoint which controls lights
}

There are a lot of NLP services out there that are available today for developers. For this example, I’m going to show the LUIS project from Microsoft because it is free to use.

LUIS is a completely visual tool, so we won’t actually be writing any code at all. We’ve already talked about Intents and Entities, so you already know most of the terminology that you need to know to build this interface.

The first step is to create a “Control Lights” intent in LUIS.

Large preview

Before I do anything with that intent, I need to define my Location and Power entities. Entities can be different types — kind of like types in a programming language. You can have dates, lists and even entities that are related to other entities. In this case, Power is a list of values (on, off) and Location is a simple entity, which can be any value.

It will be up to LUIS to be smart enough to figure out exactly what the Location is.

Large preview

Large preview

Now we can begin to train this model to understand all of the different ways that we might ask it to control the lights in a different location. Let’s think of all the different ways that we could do that:

Turn off the kitchen lights;
Turn off the lights in the office;
The lights in the living room, turn them on;
Lights, kitchen, off;
Turn off the lights (no location).

As I feed these into the Control Lights intent as utterances, LUIS tries to determine where in the intent the entities are. You can see that because Power is a discreet list of values, it gets that right every time.

Large preview

But it has no idea what a Location even is. LUIS wants us to go through this list and tell it where the Location is. That’s done by clicking on a word or group of words and assigning to the right entity. As we are doing this, we are really creating a machine learning model that LUIS is going to use to statistically estimate what qualifies as a Location.

Large preview

When I’m done telling LUIS where in these utterances all the locations are, my dashboard looks like this…

Large preview

Now we train the model by clicking on the “Train” button at the top. Do you feel like a data scientist yet?

Now I can test it using the test panel. You can see that LUIS is already pretty smart. The Power is easy to pick out, but it can actually pick out Locations it has never seen before. It’s doing what your brain does — using the information that it has to make an educated guess. Machine Learning is equal parts impressive and scary.

Large preview

If we try hard enough, we can fool the AI. The more utterances we give it and label, the smarter it will get. I added 35 utterances to mine before I was done and it is close to bullet proof.

So now we get to the important part, which is how we actually use this NLP in an app. LUIS has a “Publish” menu option which allows us to publish our model to the internet where it’s exposed via a single HTTP endpoint. It will look something like this…

https://westus.api.cognitive.microsoft.com/luis/v2.0/apps/c4396135-ee3f-40a9-8b83-4704cddabf7a?subscription-key=19d29a12d3fc4d9084146b466638e62a&verbose=true&timezoneOffset=0&q=

The very last part of that query string is a q= variable. This is where we would pass our intent.

https://westus.api.cognitive.microsoft.com/luis/v2.0/apps/c4396135-ee3f-40a9-8b83-4704cddabf7a?subscription-key=19d29a12d3fc4d9084146b466638e62a&verbose=true&timezoneOffset=0&q=turn on the kitchen lights

The response that we get back looks is just a JSON object.

{
“query”: “turn on the kitchen lights”,
“topScoringIntent”: {
“intent”: “Control Lights”,
“score”: 0.999999046
},
“intents”: [
{
“intent”: “Control Lights”,
“score”: 0.999999046
},
{
“intent”: “None”,
“score”: 0.0532306843
}
],
“entities”: [
{
“entity”: “kitchen”,
“type”: “Location”,
“startIndex”: 12,
“endIndex”: 18,
“score”: 0.9516622
},
{
“entity”: “on”,
“type”: “Power”,
“startIndex”: 5,
“endIndex”: 6,
“resolution”: {
“values”: [
“on”
]
}
}
]
}

Now this is something that we can work with as developers! This is how you add NLP to any project — with a single REST endpoint. Now you’re free to create a bot with some real brains!

Brian Holt used the browser speech API and a LUIS model to create a voice powered calculator that is running right inside of CodePen. Chrome is required for the speech API.

See the Pen Voice Calculator by Brian Holt (@btholt) on CodePen.

Bot Design Is Still Hard

Having a smart bot is only half the battle. We still need to account for any of the actions that our system might expose, and that can lead to a lot of different logical paths which makes for messy code.

Conversations also happen in stages, so the bot needs to be able to intelligently direct users down the right path without frustrating them or being unable to recover when something goes wrong. It needs to be able to recover when the conversation dies midstream and then starts again. That’s a whole other article and I’ve included some resources below to help.

When it comes to language understanding, the AI platforms are mature and ready to use today. While that won’t help you perfectly design your bot, it will be a key component to building a bot that people don’t hate.

Great UI Is Just Great UI

A final note: As we saw from the AT&T example, a truly smart interface combines great speech recognition, Natural Language Processing, different types of conversational UI (speech and text) and even a visual UI. In short, great UI is just that — great UI — and it is not a zero sum game. Great UIs will leverage all of the technology available to provide the best possible user experience.

Special thanks to Mat Velloso for his input on this article.

Further Resources:

“Principles Of Bot Design,” Microsoft Azure (Doc written by Mat Velloso, Kamran Iqbal, and Robert Standefer)
“Conversational Design Essentials: Tips For Building A Chatbot,” Anton Skorniakov, Smashing Magazine
“Language Understanding Tutorials,” LUIS, Microsoft Azure

Smashing Editorial
(rb, ra, yk, il)

How to Change macOS Screenshot File Format

Original Source: https://www.hongkiat.com/blog/change-macos-screenshot-file-format/

Learn how to change the default .PNG file format of macOS screenshots into any other format.

Visit hongkiat.com for full content.

Collective #403

Original Source: http://feedproxy.google.com/~r/tympanus/~3/FEbYiJbkAIo/

C403_designres

Public Design Vault

Public Design Vault is a curated directory of 500+ design tools and resources for public good.

Check it out

C403_Udemy

Our Sponsor
Ever find yourself thinking “I wish I could do that?”

With Udemy, you can. From web development to digital marketing to cooking courses, Udemy has something for everyone for as low as $10.99. Plus, each course comes with a 30-day money-back guarantee for risk-free learning.

Pick your course

C403_palette

Site Palette

A browser extension that extracts the essential colors of a website.

Check it out

C403_console

Consola

An easy-to-use console logger with a fancy output style.

Check it out

C403_logical

Understanding Logical Properties And Values

A great article by Rachel Andrew where she explains logical properties and values in CSS.

Read it

C403_Tensorflow

Introducing TensorFlow.js: Machine Learning in Javascript

Read about TensorFlow.js, an open-source JavaScript library for defining, training and running machine learning models in the browser.

Read it

C403_customprop

Contextual styling with custom properties

An interesting article that describes how to have multiple themes on the same page using custom properties.

Read it

C403_rssrevival

It’s Time for an RSS Revival

A nice reminder on how great RSS is by giving us updates on the content that we really care about.

Read it

C403_lineheight

Cropping Away Negative Impacts of Line Height

In case you missed it: Kevin Powell shows how to get rid of pesky space above and below HTML text.

Read it

C403_glitch

Glitch Opens Up: Welcome!

Read about the future of Glitch which is now out of beta.

Read it

C403_hackernewsapp

Building a HackerNews Clone in VueJS

Learn how to build a simplistic version of HackerNews in VueJS from scratch in this tutorial series.

Read it

C403_jsml

11 JavaScript Machine Learning Libraries To Use In Your App

Jonathan Saring shares some libraries which bring JavaScript, Machine Learning, DNN and even NLP together.

Read it

C403_instagram

Instagram Terminal Feed

A fun project made by Bill Cheng.

Check it out

C403_robots

The Famous Robots Icon Set

A fantastic freebie of 20 robot icons in AI, SVG and PNG. Designed by Iconshock.

Get it

C403_radial

Animated SVG Radial Progress Bars

Dave Rupert shows how to create a circular progress indicator.

Read it

C403_goo

Transitioning Google URL Shortener to Firebase Dynamic Links

Read about Google’s plan to retire its URL Shortener service.

Read it

C403_font

Free Font: Riviera

Rachel Woodby designed this interesting display typeface.

Get it

C403_define

Define

A command-line dictionary (thesaurus) app with access to multiple sources, written in Go.

Check it out

C403_Backgroundcolor

Solved With CSS! Colorizing SVG Backgrounds

Una Kravets shares a CSS trick for coloring background images using filters.

Read it

C403_listmindmap

Text2MindMap

An online tool for making mind maps by writing indented lists.

Check it out

C403_GridMenu

From Our Blog
Expanding Grid Menu

A CSS Grid powered menu with a box look inspired by the effect seen in the “Ableton Live 10: What’s New” video.

Check it out

Collective #403 was written by Pedro Botelho and published on Codrops.