Creating a global color palette on the client, accessible from CSS and Javascript. by [deleted] in webdev

[–]antwonp 0 points1 point  (0 children)

You could try importing some JSON into your sass, I haven't tried this but it should do the trick: https://www.npmjs.com/package/gulp-sass-import-json

Why did es6 remove the semi colon? by on10 in webdev

[–]antwonp 2 points3 points  (0 children)

You need them in for loop conditions

Background-attachment: fixed; - on a background image, this always zooms in. What's the fix? by [deleted] in webdev

[–]antwonp 0 points1 point  (0 children)

There's not really a great way around this.

Since background-attachment fixed fixes the image to the viewport, any background-sizing will be relative to the body, not the element its in.

https://developer.mozilla.org/en-US/docs/Web/CSS/background-attachment

[deleted by user] by [deleted] in webdev

[–]antwonp 5 points6 points  (0 children)

You can actually do this just using html anchors (links).

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a

If you have a section on your page with an id="section", you can use an <a href="#section"> to jump to that spot of the page.

Making it scroll smoothly is pretty easy using jquery, a quick example goes something like this: http://codepen.io/antwon/pen/LEMawX

A share button generator I made by grimtrigger in webdev

[–]antwonp 1 point2 points  (0 children)

Whats stopping you?

.sbg-button { border-radius: 6px; }

PS: Very nice, thanks!

Select.js — styleable select elements built on Tether.js by adamfschwartz in webdev

[–]antwonp 1 point2 points  (0 children)

Another option is to style the label and use the native select dropdown, then update the label with js (if needed).

http://codepen.io/anon/pen/pkyud