MDL-61460 tool_componentlibrary: Additional whitespace removal.

This commit is contained in:
Adrian Greeve 2021-07-08 15:33:24 +08:00 committed by Eloy Lafuente (stronk7)
parent f21ac401e2
commit 18515919e1
6 changed files with 69 additions and 69 deletions

View File

@ -26,7 +26,7 @@ Rendered result on this page:
{{< highlight html >}}
<div class="myclass">
This is an example.
This is an example.
</div>
{{< /highlight >}}
@ -42,7 +42,7 @@ Syntax for markdown (.md) files:
Rendered result on this page:
{{< php >}}
$mform->addElement('passwordunmask', 'password', get_string('label'), $attributes);
$mform->addElement('passwordunmask', 'password', get_string('label'), $attributes);
{{< /php >}}
## Highlight shortcode

View File

@ -95,28 +95,28 @@ Use primary buttons for the positive action on the page, for example "Save" or "
{{< example >}}
<div class="row">
<div class="col-5">
<div class="card mb-2">
<div class="card-body">
<strong>Save Changes?</strong>
<div class="d-flex">
<button type="button" class="btn btn-secondary mr-1">Cancel</button>
<button type="button" class="btn btn-primary mr-1">Save</button>
</div>
</div>
</div>
</div>
<div class="col-5">
<div class="card mb-2">
<div class="card-body">
<strong>Delete profile</strong>
<div class="d-flex">
<button type="button" class="btn btn-primary mr-1">Cancel</button>
<button type="button" class="btn btn-secondary">Delete</button>
</div>
</div>
</div>
</div>
<div class="col-5">
<div class="card mb-2">
<div class="card-body">
<strong>Save Changes?</strong>
<div class="d-flex">
<button type="button" class="btn btn-secondary mr-1">Cancel</button>
<button type="button" class="btn btn-primary mr-1">Save</button>
</div>
</div>
</div>
</div>
<div class="col-5">
<div class="card mb-2">
<div class="card-body">
<strong>Delete profile</strong>
<div class="d-flex">
<button type="button" class="btn btn-primary mr-1">Cancel</button>
<button type="button" class="btn btn-secondary">Delete</button>
</div>
</div>
</div>
</div>
</div>
{{< /example >}}
@ -135,31 +135,31 @@ The meaning of buttons must be very clear.
{{< example show_markup="false">}}
<div class="row">
<div class="col-5">
<div class="card mb-2">
<div class="card-body">
<strong>Save Changes?</strong>
<p>Would you like to not save your changes before exiting?</p>
<div class="d-flex">
<button type="button" class="btn btn-primary mr-1">Yes</button>
<button type="button" class="btn btn-secondary">No</button>
</div>
</div>
</div>
<div class="alert alert-warning">Avoid generic 'OK' or 'Yes', avoid confusing phrases</div>
</div>
<div class="col-5">
<div class="card mb-2">
<div class="card-body">
<strong>Save Changes</strong>
<p>Would you like to save your changes before exiting?</p>
<div class="d-flex">
<button type="button" class="btn btn-primary mr-1">Save</button>
<button type="button" class="btn btn-secondary">Discard</button>
</div>
</div>
</div>
<div class="alert alert-success">Avoid generic 'OK' or 'Yes', avoid confusing phrases</div>
</div>
<div class="col-5">
<div class="card mb-2">
<div class="card-body">
<strong>Save Changes?</strong>
<p>Would you like to not save your changes before exiting?</p>
<div class="d-flex">
<button type="button" class="btn btn-primary mr-1">Yes</button>
<button type="button" class="btn btn-secondary">No</button>
</div>
</div>
</div>
<div class="alert alert-warning">Avoid generic 'OK' or 'Yes', avoid confusing phrases</div>
</div>
<div class="col-5">
<div class="card mb-2">
<div class="card-body">
<strong>Save Changes</strong>
<p>Would you like to save your changes before exiting?</p>
<div class="d-flex">
<button type="button" class="btn btn-primary mr-1">Save</button>
<button type="button" class="btn btn-secondary">Discard</button>
</div>
</div>
</div>
<div class="alert alert-success">Avoid generic 'OK' or 'Yes', avoid confusing phrases</div>
</div>
</div>
{{< /example >}}

View File

@ -18,17 +18,17 @@ Show what the example looks like in Moodle, if your component includes and JavaS
{{< example >}}
<div class="example w-25 border border-secondary p-3">
<button class="btn btn-primary btn-block" id="clickme">
Click me
<span id="waiting" class="spinner-grow-sm" role="status" aria-hidden="true"></span>
</button>
<button class="btn btn-primary btn-block" id="clickme">
Click me
<span id="waiting" class="spinner-grow-sm" role="status" aria-hidden="true"></span>
</button>
</div>
{{#js}}
require(['jquery'], function($) {
$('#clickme').on('click', function() {
$('#waiting').toggleClass('spinner-grow');
});
$('#clickme').on('click', function() {
$('#waiting').toggleClass('spinner-grow');
});
});
{{/js}}
{{< /example >}}
@ -54,4 +54,4 @@ Is there a webservice backend required?
Descripbe the `aria-something` parts of the element. Are there any possible accessibility issues using this example?
What are the considerations for keyboard navigation?
What accessibile colors can be used?
How to test its accessibility?
How to test its accessibility?

View File

@ -34,9 +34,9 @@ The page footer is required to inject the page JavaScript, show the reset user t
{{< example >}}
<footer id="page-footer" class="py-3 bg-dark text-light">
<div class="container">
<p class="helplink"><a href="#">Moodle docs for this page</a></p>
You are logged in as <a href="#">Test User</a> (<a href="#">logout</a>)
<a href="#">Home</a>
<p class="helplink"><a href="#">Moodle docs for this page</a></p>
You are logged in as <a href="#">Test User</a> (<a href="#">logout</a>)
<a href="#">Home</a>
<div class="tool_usertours-resettourcontainer"></div>
</div>
</footer>

View File

@ -26,13 +26,13 @@ $string['copied'] = 'Copied!';
$string['copy'] = 'Copy';
$string['copytoclipboard'] = 'Copy to clipboard';
$string['installer'] = '<h3>Please setup this component library</h3>
<p>Before you can see the content of the component library you will need to have shell access to your Moodle installation and be able to write to folder /admin/tool/componentlibrary and have npm installed on your Moodle server.</p>
<p>If you meet these requirements you can navigate to your Moodle root folder and run:</p>
<pre>$ npm install</pre>
<p>Before you can see the content of the component library you will need to have shell access to your Moodle installation and be able to write to folder /admin/tool/componentlibrary and have npm installed on your Moodle server.</p>
<p>If you meet these requirements you can navigate to your Moodle root folder and run:</p>
<pre>$ npm install</pre>
<pre>$ npm install grunt</pre>
<p>This will fetch all the required packages for building the component library docs.</p>
<p>Once they are installed you can run:</p>
<pre>$ grunt componentlibrary</pre>
<p>This will fetch all the required packages for building the component library docs.</p>
<p>Once they are installed you can run:</p>
<pre>$ grunt componentlibrary</pre>
<p>For more info see the README.md file in this plugin</p>';
$string['pluginname'] = 'UI Component library';
$string['privacy:metadata'] = 'The Component library plugin does not store any personal data.';

View File

@ -24,5 +24,5 @@
}
}}
<div class="text-left my-5 w-50 mx-auto">
{{#str}} installer, tool_componentlibrary {{/str}}
</div>
{{#str}} installer, tool_componentlibrary {{/str}}
</div>