Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.foo p + p not process? #50

Closed
katopz opened this issue Dec 22, 2016 · 2 comments
Closed

.foo p + p not process? #50

katopz opened this issue Dec 22, 2016 · 2 comments

Comments

@katopz
Copy link

katopz commented Dec 22, 2016

To reproduce

  render () {
    return (
        <div>
          <dl className="foo">
            <style jsx>{`
              .foo {
                color: red; 
              }
              .foo p {
                color: green; 
              }
              .foo p + p {
                color: blue; 
              }
              `}
            </style>
            red<p>green</p><p>blue</p>
          </dl>
        </div>
    )
  }

Preact (Working)
screen shot 2016-12-22 at 18 10 29

React via vercel/next.js@cae706d (Not working)
screen shot 2016-12-22 at 18 10 19

Also sometime hot reload refuse to process CSS (all appear no colour just black) and will need full refresh.
Is it a bug? Thanks.

@katopz
Copy link
Author

katopz commented Dec 24, 2016

@rauchg Thanks. It's work now but maybe it's not cover this case?

// Bar.js
export default () =>
<div>
	<dd className='bar'>
		red<p>green</p><p>blue</p>
	</dd>
</div>;
// Foo.js
import React from 'react'
import Bar from './Bar'

export default Foo => {
	return (
		<div>
			<dl className="foo">
				<style jsx>{`
					.foo {
						color: red; 
					}
					.foo p {
						color: green; 
					}
					.foo p + p {
						color: blue; 
					}
					`}
				</style>
				red<p>green</p><p>blue</p>
				{
					[0,1,2].map(item => <Bar key={item}/>)
				}
			</dl>
		</div>
	)
};

Expected
screen shot 2016-12-24 at 22 39 18

But get
screen shot 2016-12-24 at 22 39 02

Do tell me if I need to open new issue.

Thanks

@nkzawa
Copy link
Contributor

nkzawa commented Dec 25, 2016

@katopz that'a bit different issue, see #42

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants