question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unknown 'gray2' in multiple components

See original GitHub issue

I’ve noticed there’s invalid color gray2 set on multiple components (Input, Select, Textarea, Slider, Border, Card, Progress, Tabs) background-colors and box shadows set by default. Thus the intended properties don’t render.

A sample code from my page:

.iUtigF {
	font-family: inherit;
	line-height: inherit;
	display: inline-block;
	vertical-align: middle;
	border: 0;
	box-shadow: inset 0 0 0 1px gray2;
	border-radius: 25px;
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	text-align: center;
	font-weight: 400;
}

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:1
  • Comments:11 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
epilandecommented, Sep 24, 2017

@mannie-faux Ah palx returns an array of grays, that’s why you’re able to access it with colors.gray[2], but rebass looks for colors.gray2. The array needs to be flattened onto the colors object.

Rebass also use palx to generate colors then flattens it to a single colors object. https://github.com/jxnblk/rebass/blob/29701cbd394925d9d4b1f69d7d9a0b34cf69df3a/src/theme.js#L38-L59

1reaction
epilandecommented, Sep 22, 2017

@selrond @mannie-faux this is because the components don’t have the theme context.

Rebass has a <Provider /> component that will properly configure the theme, just need to use it at the root of your application.

See http://jxnblk.com/rebass/theming.

Read more comments on GitHub >

github_iconTop Results From Across the Web

[Convert3D][1] Documentation - itk-SNAP
This section discusses images with multiple components, where each voxel contains more than one value. For example color (RGB) images and ...
Read more >
Insights Into the Pacific Deep-Sea Following NOAA ... - Frontiers
This category includes several types of unknowns: (a) unclassified species that are new to science, (b) organisms that require microscopy ...
Read more >
Unknown / Home Appliances: Tools & Home Improvement
Online shopping for Tools & Home Improvement from a great selection of Air Conditioners & Accessories & more at everyday low prices.
Read more >
PNG Specification: Chunk Specifications - W3C
A valid PNG image must contain an IHDR chunk, one or more IDAT chunks, ... the absence of a gAMA chunk indicates that...
Read more >
Answers to All Questions and Problems
He discovered that genes exist in different forms, which we now call alleles. Each organism carries two copies of each gene. During reproduction ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found