How to make chart fit the react-tabs inside React-Grid-Layout?
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Accessibilité débutants
- 20/100
- Type d'issue
- Bug
- Clarté
- À clarifier
- Activité
- À l'abandon
- Stack technique
- javascript, react
- Domaine
- frontend
Piste de recherche
Aucun fichier du dépôt ni aucun test n’est indiqué. Commencez par reproduire la disposition imbriquée de React-Grid-Layout, react-tabs et TVChartContainer décrite dans l’issue, puis examinez comment la hauteur et la largeur sont transmises à travers les panneaux d’onglets. La tâche est terminée lorsqu’un correctif au niveau du dépôt a été identifié ou que le comportement de dimensionnement requis a été documenté avec un test de régression, si le projet en prend un en charge.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
Hi @danez
Please help. I want put the chart in a tab of a grid. I have successfully put the chart in the grid (React Grid Layout) and the chart size fits the grid, but when i put tab (React-Tab) in a grid and then the chart inside the tab. The chart wont fit anymore. How to solve?
class TvChart extends React.Component {
render() {
return (
<div>
<Tabs style={this.props.style}>
<TabList>
<Tab>Chart</Tab>
<Tab>Depth</Tab>
</TabList>
<TabPanel>
<Card>
<TVChartContainer />
</Card>
</TabPanel>
<TabPanel>
<h5>Depth</h5>
</TabPanel>
</Tabs>
</div>
);
}
}
this is the css
.TVChartContainer {
height: 100%;
width: 100%;
}
and this is the parent style
const styles = {
main: {
backgroundColor: "#ffffff",
fontSize: "10px",
height: "inherit"
},
orderbook: {
minHeight: "220px",
minWidth: "100px"
},
ask: {
width: "50%"
},
bid: {
width: "50%",
borderRight: "1px solid #151d2b"
}
};
but this one works, the chart fits the grid completely.
class TvChart extends React.Component {
render() {
return (
<Card style={this.props.style.main}>
<TVChartContainer />
</Card>
);
}
}
I appreciate if you can help.
Regards,
Ian
- Langage dominant
- JavaScript
- Étoiles
- 3.1k
- Forks
- 455
- Merge moyen
- 5 h 9 min
- PR mergées (30 j)
- 2
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de reactjs/react-tabs
-
Difficulté 3/5 1-2 jours Accessibilité débutants 25/100
reactjs/react-tabs#584 ·
-
Difficulté 2/5 1-3 heures Accessibilité débutants 45/100
reactjs/react-tabs#581 · 3 commentaires ·
-
Difficulté 3/5 1-2 jours Accessibilité débutants 35/100
reactjs/react-tabs#571 ·
-
Support hiding of all TabPanels Ouverte
Difficulté 4/5 3-5 jours Accessibilité débutants 35/100
reactjs/react-tabs#525 · 1 commentaire · 1 réaction ·
-
Difficulté 3/5 1-2 jours Accessibilité débutants 35/100
reactjs/react-tabs#521 · 3 commentaires ·
Toutes les issues de reactjs/react-tabs
Issues similaires
-
Update HugeIcons library Ouverte
Difficulté 2/5 1-3 heures Accessibilité débutants 65/100
antfu-collective/icones#398 ·
-
ECmail.com Ouverte
Difficulté 1/5 Moins d'une heure Accessibilité débutants 90/100
wesbos/burner-email-providers#554 ·
-
Difficulté 2/5 1-3 heures Accessibilité débutants 65/100
radiantearth/stac-browser#1023 ·
-
HMR stops working Ouverte
Difficulté 2/5 1-3 heures Accessibilité débutants 75/100
-
Difficulté 2/5 1-3 heures Accessibilité débutants 75/100
components-web-app/docs#92 ·