1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
|
### panel/demo

<details>
<summary>SHOW SOURCE</summary>
```go
package main
import "github.com/pterm/pterm"
func main() {
// Define panels in a 2D grid system
panels := pterm.Panels{
{
{Data: "This is the first panel"},
{Data: pterm.DefaultHeader.Sprint("Hello, World!")},
{Data: "This\npanel\ncontains\nmultiple\nlines"},
},
{
{Data: pterm.Red("This is another\npanel line")},
{Data: "This is the second panel\nwith a new line"},
},
}
// Render the panels with a padding of 5
_ = pterm.DefaultPanel.WithPanels(panels).WithPadding(5).Render()
}
```
</details>
|