- First task of v2 done
This commit is contained in:
1 parent
30ddd4c98b
commit
5397ed4fae
50 files changed
+237
-105
No files matched your search
+8
-8
@@ -10,7 +10,7 @@ Mostly everything you need to build and process form is available in this packag
|
||||
The first part is most input callable as a widget :
|
||||
|
||||
```
|
||||
{% ui.text "fullname", "John Doe" %}
|
||||
{% ui:text "fullname", "John Doe" %}
|
||||
```
|
||||
|
||||
Current input support is :
|
||||
@@ -41,30 +41,30 @@ Current input support is :
|
||||
**[PICEA]** So, using this code:
|
||||
|
||||
```html
|
||||
{% ui.form.post "user.save", current_url() %}
|
||||
{% ui:form.post "user.save", current_url() %}
|
||||
<div class="field fullname">
|
||||
<label>Full name</label>
|
||||
{% ui.text "fullname", $user->fullname, [ 'required' => 'required' ] %}
|
||||
{% ui:text "fullname", $user->fullname, [ 'required' => 'required' ] %}
|
||||
</div>
|
||||
|
||||
<div class="field email">
|
||||
<label>Email address</label>
|
||||
{% ui.text "email", $user->email %}
|
||||
{% ui:text "email", $user->email %}
|
||||
</div>
|
||||
|
||||
<div class="field job">
|
||||
<label>Have a job</label>
|
||||
<label>{% ui.radio "job", 'yes', [], [ 'value' => $entity->job ] %} Yes</label>
|
||||
<label>{% ui.radio "job", 'no', [], [ 'value' => $entity->job ] %} No</label>
|
||||
<label>{% ui:radio "job", 'yes', [], [ 'value' => $entity->job ] %} Yes</label>
|
||||
<label>{% ui:radio "job", 'no', [], [ 'value' => $entity->job ] %} No</label>
|
||||
</div>
|
||||
|
||||
<div class="field role">
|
||||
<label>Role</label>
|
||||
{% ui.select "role", [ 'user' => "User", 'moderator' => "Moderator", 'admin' => "Admin" ], $user->role, [ 'required' => 'required' ] %}
|
||||
{% ui:select "role", [ 'user' => "User", 'moderator' => "Moderator", 'admin' => "Admin" ], $user->role, [ 'required' => 'required' ] %}
|
||||
</div>
|
||||
|
||||
<button type="submit">Save</button>
|
||||
{% ui.endform %}
|
||||
{% ui:endform %}
|
||||
```
|
||||
|
||||
**[HTML]** Would render as such:
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# `ui.checkbox` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:checkbox` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.radio` component, which itself extends `ui.input`.
|
||||
Built on top of `ui:radio` component, which itself extends `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.color` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:color` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.date` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:date` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# `ui.datetime` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:datetime` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.email` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:email` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.file` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:file` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.form` / `ui.form.get` / `ui.form.post` (string $method = "get", string $name = "", string $action = "", array $attributes = [])
|
||||
# `ui:form` / `ui:form.get` / `ui:form.post` (string $method = "get", string $name = "", string $action = "", array $attributes = [])
|
||||
|
||||
A version exists also for unsupported methods (as of HTML5) on forms `ui.form.put` / `ui.form.patch` / `ui.form.delete`, which
|
||||
A version exists also for unsupported methods (as of HTML5) on forms `ui:form.put` / `ui:form.patch` / `ui:form.delete`, which
|
||||
could find a use within a Javascript environment.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# `ui.hidden` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:hidden` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.image` (string $source, array $attributes = [], array $options = [])
|
||||
# `ui:image` (string $source, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
# `ui.input` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:input` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
This is small
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# `ui.numeric` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:numeric` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# `ui.password` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:password` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.radio` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:radio` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.range` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:range` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# `ui.search` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:search` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# `ui.select` (string $name, array $list, $value = null, array $attributes = [], bool $strictComparison = true)
|
||||
# `ui:select` (string $name, array $list, $value = null, array $attributes = [], bool $strictComparison = true)
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.tel` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:tel` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.text` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:text` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# `ui.textarea` / `ui.textarea.raw` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:textarea` / `ui:textarea.raw` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`. This extension also comes with a raw modifier which skips the escaping.
|
||||
Built on top of `ui:input`. This extension also comes with a raw modifier which skips the escaping.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.time` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:time` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.url` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:url` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
# `ui.week` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
# `ui:week` (string $name, mixed $value = null, array $attributes = [], array $options = [])
|
||||
|
||||
Built on top of `ui.input`.
|
||||
Built on top of `ui:input`.
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# `ui.popup` (string $name, array $variables = [], array $options = [])
|
||||
# `ui:popup` (string $name, array $variables = [], array $options = [])
|
||||
|
||||
The following attributes are assigned by this extension :
|
||||
|
||||
|
||||
Reference in new issue
Block a user