Skip to content

Commit a68c544

Browse files
authored
Update example_art.php
1 parent 0be9a65 commit a68c544

1 file changed

Lines changed: 60 additions & 2 deletions

File tree

examples/example_art.php

Lines changed: 60 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,63 @@
11
<?php
22
require __DIR__ . '/../vendor/autoload.php';
33

4-
$cli = new WizardCLI\WizardCLI(['theme' => 'sorcerer']);
5-
$cli->art("WizardCLI");
4+
// Array of all themes you want to demonstrate:
5+
$themes = ['wizard', 'sorcerer', 'dark', 'gold', 'emerald'];
6+
7+
// List of texts to render as banners
8+
$texts = [
9+
"WizardCLI",
10+
"ASCII Art Demo",
11+
"Magic Terminal",
12+
"Hello, World!",
13+
"✨ Wizard Power ✨",
14+
"Theme Showcase"
15+
];
16+
17+
// Print each text in each theme
18+
foreach ($themes as $theme) {
19+
$cli = new WizardCLI\WizardCLI(['theme' => $theme]);
20+
$cli->color(str_repeat("=", 15) . " Theme: " . ucfirst($theme) . " " . str_repeat("=", 15), "yellow+bold");
21+
foreach ($texts as $text) {
22+
$cli->art($text);
23+
}
24+
echo PHP_EOL;
25+
}
26+
27+
// Demonstrate colored banners with different text styles
28+
$cli = new WizardCLI\WizardCLI(['theme' => 'wizard']);
29+
$cli->color("Magic banner (magenta+bold):", "magenta+bold");
30+
$cli->art("🧙‍♂️ Magic Banner 🧙‍♂️");
31+
32+
$cli->color("Dark theme banner (cyan):", "cyan");
33+
$cli = new WizardCLI\WizardCLI(['theme' => 'dark']);
34+
$cli->art("Dark Mode!");
35+
36+
// Very long banner text
37+
$cli = new WizardCLI\WizardCLI(['theme' => 'gold']);
38+
$cli->color("Very long banner text:", "yellow+bold");
39+
$cli->art("This is a very long banner text to test wrapping and alignment!");
40+
41+
// Unicode symbols in banner
42+
$cli = new WizardCLI\WizardCLI(['theme' => 'emerald']);
43+
$cli->color("Banner with Unicode:", "green+bold");
44+
$cli->art("🌟🌍🚀✨");
45+
46+
// Multilingual banners
47+
$cli = new WizardCLI\WizardCLI(['theme' => 'wizard']);
48+
$cli->color("Multilingual banner (Hebrew):", "magenta+bold");
49+
$cli->art("קוסם בטרמינל");
50+
51+
$cli->color("Multilingual banner (Russian):", "cyan+bold");
52+
$cli->art("ВОЛШЕБНИК");
53+
54+
// Fancy spacing & mixed theme
55+
foreach ($themes as $theme) {
56+
$cli = new WizardCLI\WizardCLI(['theme' => $theme]);
57+
$cli->color("Theme [$theme] - Mixed Text Demo:", "yellow+bold");
58+
$cli->art("$theme");
59+
echo PHP_EOL;
60+
}
61+
62+
$cli = new WizardCLI\WizardCLI(['theme' => 'wizard']);
63+
$cli->color("Done!", "magenta+bold");

0 commit comments

Comments
 (0)