examples: Drop PatternFly 3 and patternfly.css

These both have been deprecated for years, and patternfly.css does not
exist anywhere except on RHEL 8. So just use standard HTML elements for
these examples. If PF ever comes back for these, it would have to be
through webcomponents or something similar which does not need a build
chain.
This commit is contained in:
Martin Pitt 2022-06-23 09:19:06 +02:00 committed by Martin Pitt
parent 6e06b05487
commit de2c8932e4
9 changed files with 69 additions and 91 deletions

View File

@ -3,7 +3,6 @@
<head>
<title>Launch and reattach to long-running process</title>
<meta charset="utf-8">
<link href="./patternfly.css" type="text/css" rel="stylesheet">
<link href="long-running.css" type="text/css" rel="stylesheet">
<script src="../base1/cockpit.js"></script>
<script type="module" src="long-running-process.js"></script>
@ -11,26 +10,22 @@
</head>
<body>
<div class="pf-c-page">
<main class="pf-c-page__main" tabindex="-1">
<section class="pf-c-page__main-section pf-m-light">
<div class="pf-l-stack pf-m-gutter">
<div class="pf-l-stack__item">
<label for="state">State:</label>
<span id="state"></span></p>
</div>
<div class="pf-l-stack__item">
<input id="command" type="text" />
<button class="pf-c-button pf-m-primary" id="run" disabled>Start</button>
</div>
<div class="pf-l-stack__item pf-m-fill">
<pre id="output"></pre>
</div>
<main tabindex="-1">
<section>
<div>
<div>
<label for="state">State:</label>
<span id="state"></span></p>
</div>
</section>
</main>
</div>
<div>
<input id="command" type="text" />
<button id="run" disabled>Start</button>
</div>
<pre id="output"></pre>
</div>
</section>
</main>
</body>
</html>

View File

@ -1 +0,0 @@
../../node_modules/@patternfly/patternfly/patternfly.css

View File

@ -1 +0,0 @@
../../node_modules/@patternfly/patternfly/patternfly.css

View File

@ -1 +0,0 @@
../../node_modules/@patternfly/patternfly/patternfly.css

View File

@ -3,29 +3,26 @@
<head>
<title>Pinger</title>
<meta charset="utf-8">
<link href="./patternfly.css" type="text/css" rel="stylesheet">
<script src="../base1/cockpit.js"></script>
</head>
<body>
<div class="pf-c-page">
<main class="pf-c-page__main" tabindex="-1">
<section class="pf-c-page__main-section pf-m-light">
<div class="pf-l-stack pf-m-gutter">
<div class="pf-l-stack__item">
<label for="address">Address</label>
<input id="address" value="8.8.8.8">
</div>
<div class="pf-l-stack__item">
<button class="pf-c-button pf-m-primary" id="ping">Ping</button>
<span id="result"></span>
</div>
<div class="pf-l-stack__item pf-m-fill">
<pre id="output"></pre>
</div>
<main tabindex="-1">
<section>
<div>
<div>
<label for="address">Address</label>
<input id="address" value="8.8.8.8">
</div>
</section>
</main>
</div>
<div>
<button id="ping">Ping</button>
<span id="result"></span>
</div>
<div>
<pre id="output"></pre>
</div>
</div>
</section>
</main>
<script src="pinger.js"></script>
</body>

View File

@ -1 +0,0 @@
../../node_modules/@patternfly/patternfly/patternfly.css

View File

@ -3,33 +3,28 @@
<head>
<title>XMLHttpRequest proxy</title>
<meta charset="utf-8">
<link href="./patternfly.css" type="text/css" rel="stylesheet">
<script src="../base1/cockpit.js"></script>
</head>
<body>
<div class="pf-c-page">
<main class="pf-c-page__main" tabindex="-1">
<section class="pf-c-page__main-section pf-m-light">
<div class="pf-l-stack pf-m-gutter">
<div class="pf-l-stack__item">
<label for="address">URL</label>
<input id="address" value="http://localhost:12345">
</div>
<div class="pf-l-stack__item">
<button class="pf-c-button pf-m-primary" id="get">GET request</button>
</div>
<div class="pf-l-stack__item">
<label for="result">Code</label>
<span id="result"></span>
</div>
<div class="pf-l-stack__item">
<label for="output">Output</label>
<pre id="output"></pre>
</div>
<main tabindex="-1">
<section>
<div>
<div>
<label for="address">URL</label>
<input id="address" value="http://localhost:12345">
<button id="get">GET request</button>
</div>
</section>
</main>
</div>
<div>
<label for="result">Code</label>
<span id="result"></span>
</div>
<div>
<label for="output">Output</label>
<pre id="output"></pre>
</div>
</div>
</section>
</main>
<script src="xhrproxy.js"></script>
</body>

View File

@ -1 +0,0 @@
../../node_modules/@patternfly/patternfly/patternfly.css

View File

@ -1,32 +1,29 @@
<head>
<title>Time Zone</title>
<meta charset="utf-8">
<link href="./patternfly.css" type="text/css" rel="stylesheet">
<script src="../base1/cockpit.js"></script>
</head>
<body>
<div class="pf-c-page">
<main class="pf-c-page__main" tabindex="-1">
<section class="pf-c-page__main-section pf-m-light">
<div class="pf-l-stack pf-m-gutter">
<div class="pf-l-stack__item">
<label for="current">Time Zone</label>
<span id="current"></span>
</div>
<div class="pf-l-stack__item">
<label class="control-label" for="new">New Zone</label>
<input class="form-control" id="new" value="UTC">
</div>
<div class="pf-l-stack__item">
<button class="pf-c-button pf-m-primary" id="change">Change</button>
<span id="failure"></span>
</div>
<main tabindex="-1">
<section>
<div>
<div>
<label for="current">Time Zone</label>
<span id="current"></span>
</div>
</section>
</main>
</div>
<div>
<label class="control-label" for="new">New Zone</label>
<input class="form-control" id="new" value="UTC">
<button id="change">Change</button>
</div>
<div>
<span id="failure"></span>
</div>
</div>
</section>
</main>
<script>
const input = document.getElementById("new");
@ -56,4 +53,3 @@
</script>
</body>
</html>