tastejs / todomvc-app-css Goto Github PK
View Code? Open in Web Editor NEWCSS for TodoMVC apps
Home Page: http://todomvc.com
License: Creative Commons Attribution 4.0 International
CSS for TodoMVC apps
Home Page: http://todomvc.com
License: Creative Commons Attribution 4.0 International
Based on #9 and this comment from @sindresorhus i would purpose a small improvement to
.todo-list li.editing .edit
.
The width
attribute there is fixed in size by 506px
. This fact makes it break on my phone in edit mode.
Since the rest of the design is already responsive and works on all sizes (i tested), i would suggest to make this width dynamic by using
width: calc(100% - 43px)
where the 43px
reflect the margin-left
we set for compensating the toggle
element for completion.
Not sure about the browser support we have to guarantee, but this would work for most common browsers caniuse .
So, I was testing to see if my new and shiny library was working in IE after building a TodoMVC app in it (just to test stuff) and got the following:
I figured this was just something wrong with my webpack setup, but the same thing (more or less) happened when I visited http://todomvc.com/examples/react/#/ :
This should probably be fixed IMHO.
In 2.1.0 code, toggle-all input is not clickable
See original issue, tastejs/todomvc#348. We want to switch all our ids over to classes. Than we should release v2 and start porting all of our apps over.
Hello I've met an error using webpack bundling tool.
It's a simple CSS syntax error. Will reference the issue in a PR that solved the trick for me.
ERROR in ./~/todomvc-app-css/index.css
Module parse failed: /Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/todomvc-app-css/index.css Unexpected token (2:5)
You may need an appropriate loader to handle this file type.
SyntaxError: Unexpected token (2:5)
at Parser.pp$4.raise (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/node_modules/acorn/dist/acorn.js:2221:15)
at Parser.pp.unexpected (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/node_modules/acorn/dist/acorn.js:603:10)
at Parser.pp.semicolon (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/node_modules/acorn/dist/acorn.js:581:61)
at Parser.pp$1.parseExpressionStatement (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/node_modules/acorn/dist/acorn.js:966:10)
at Parser.pp$1.parseStatement (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/node_modules/acorn/dist/acorn.js:730:24)
at Parser.pp$1.parseTopLevel (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/node_modules/acorn/dist/acorn.js:638:25)
at Parser.parse (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/node_modules/acorn/dist/acorn.js:516:17)
at Object.parse (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/node_modules/acorn/dist/acorn.js:3098:39)
at Parser.parse (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/lib/Parser.js:902:15)
at DependenciesBlock.<anonymous> (/Users/esensory/ESensory/dev/playground/redux-todomvc/node_modules/webpack/lib/NormalModule.js:104:16)
@ ./src/index.jsx 19:0-52
https://codesandbox.io/s/todomvc-qfhin
toggle-all input can be checked.
toggle-all input can't be checked.
todomvc apps are very hard for me to look at because of how light and small all the text is. i ran a a11y test on the backbone example using tota11y and it showed that there were numerous insufficient contrast ratios (there's also no label for the input, but that's an issue for another todomvc repo i imagine).
i didn't see any info on how to contribute to this repo, so i'm leaving this issue instead of working on a pr, but i would be happy to help with making some css changes so that the ui is easy for more people to see!
thanks for your work on todomvc and also your time reading this <3
Not sure why outline was deliberately, removed, hiding the indication of where your keyboard focus is:
https://github.com/tastejs/todomvc-app-css/blob/master/index.css#L37
I've found that in a more accessible TodoMVC implementation, I need to add the following CSS:
/* this block re-adds the outline, to support keyboard navigation / tabbing */
:focus,
.view label:focus,
.todo-list li .toggle:focus + label,
.toggle-all:focus + label {
/* !important needed, because todomvc styles deliberately disable the outline */
outline: #d86f95 solid !important;
}
Since we're using unicode characters like ×
and ❯
, it's better to specify charset to UTF-8
in css.
When users don't specify charset in HTML, it could cause problems.
If you allow me, I'll be happy to make a PR ~
For me the "Clear completed" button is positioned wrongly, unless I include the following css:
#clear-completed::after { top: 0 }
This happens to me when updating the styles on the todomvc example from the ember.js guide. I can't see any difference in the html compared to the official todomvc page, except maybe whitespace.
Tested on Chrome 43 / Mac OS X 10.10.3.
It would be great to modularize the CSS to be shadow DOM compatible. Nested selectors like .todo-list li .toggle
or .todo-list li .edit
doesn't work inside Shadow DOM. I suggest to use BEM methodology.
This declaration is overriden by the one right below:
https://github.com/tastejs/todomvc-app-css/blob/master/index.css#L303
Is it necessary?
I'm finding this to be terribly annoying:
.todo-list li label {
white-space: pre-line;
If you generate markup that respects whitespace like:
<label ondblclick=${this.startEditing.bind(this)}>
${encode(todo.title)}
</label>
You'll end up with items looking like:
So instead of treating HTML as whitespace insignificant, in this case you need to be very conscious of it. I'd recommend defaulting back to normal unless there is a compelling reason to keep this line.
I tried deploying the NPM package to https://www.webjars.org/ but ran into a license related issue:
webjars/webjars#1612
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.