1166 Commits

Author SHA1 Message Date
Sara Arjona
54d446ce43
MDL-77708 docs: Update references from docs.moodle.org/dev 2023-09-26 10:57:33 +02:00
Huong Nguyen
c2e501e144
Merge branch 'MDL-78728-401' of https://github.com/paulholden/moodle into MOODLE_401_STABLE 2023-09-15 17:32:44 +08:00
Paul Holden
3b2690ef9c
MDL-78728 forms: correctly refer to outermost form element.
Read-only forms do not belong to a <form> element, so we can't refer
to that. Instead find the `.mform` element (which exists for regular
and read-only forms).
2023-09-04 16:43:59 +01:00
Philipp Memmel
7b105cb467 MDL-78795 core_form: Fix repeated elements JS problem
Co-authored-by: Stefan Hanauska <stefan.hanauska@csg-in.de>
2023-09-03 14:12:39 +02:00
Ilya Tregubov
d281a2bb43
Merge branch 'MDL-74429-401' of https://github.com/roland04/moodle into MOODLE_401_STABLE 2023-09-01 11:15:51 +08:00
Paul Holden
194458b229
MDL-78707 forms: improve form container collapsing mechanism.
By using a more explicit selector for matching containers we avoid
previous problems such as incorrect count, and collapsing of elements
that had the same class name.
2023-08-21 12:38:57 +01:00
Mikel Martín
09500beae2 MDL-74429 core_form: Fix element url input overflow 2023-08-16 12:41:24 +02:00
Angelia Dela Cruz
73a08e3ccd MDL-78498 Behat: Use data generators for forum posts and replies
This commit does few things:
* Replace manual forum posts and replies to use data generator.
* It also changes the code to handle social forums.
* Other behat clean-ups and optimization.

Co-authored-by: Simey Lameze <simey@moodle.com>
2023-08-01 16:08:10 +08:00
Ilya Tregubov
8cf9b77cdb
Merge branch 'MDL-73213_401' of https://github.com/pedrojordao/moodle into MOODLE_401_STABLE 2023-07-13 09:18:31 +08:00
Pedro Jordao
2ace3d54dc MDL-73213 autocomplete: keep selected value when the state changes.
The selected value of the dropdown was being cleared when the dropdown
was opened, this was causing an error when submitting the form if the
field was required. The main cause was that we were emptying the
select before loading new values, this solution was created because
of an issue where we could not deselect values if the list was
reloaded. To fix this problem, I added an empty option as the first
element of the select only when deselecting a certain item.
2023-07-06 15:33:47 -03:00
Jun Pataleta
461c0bd947
Merge branch 'MDL-78484-401' of https://github.com/NashTechOpenUniversity/moodle into MOODLE_401_STABLE 2023-07-06 09:41:24 +08:00
hieuvu
14079fa738 MDL-78484 formslib: Move enable checkbox display before the date picker 2023-06-22 11:08:47 +07:00
Jake Dallimore
331f47a4f3
MDL-78544 forms: fix string to number comparison bug in duration element
Prior to PHP 8, 0 == "", but now no more. We should use empty instead.
See: https://www.php.net/manual/en/migration80.incompatible.php
2023-06-22 11:01:17 +08:00
Andrew Nicols
46f3dc6538
Merge branch 'MDL-78478-401' of https://github.com/dasistwas/moodle into MOODLE_401_STABLE 2023-06-15 09:56:18 +08:00
David Bogner
c461b4d8fc MDL-78478 forms: Fix repeated elements in dynamic forms 2023-06-14 15:30:32 +02:00
Angelia Dela Cruz
948ac8f62b MDL-70152 behat: Forum behat generators use UI
Behat cleanup and optimisation
2023-05-29 10:28:04 +08:00
Angelia Dela Cruz
d7752f9576 MDL-70152 behat: Forum behat generators use UI
Replace steps that manually add forum and forum post instances
via the UI and use Behat generators. This improves the speed of
Behat test runs.
2023-05-29 10:27:33 +08:00
Jun Pataleta
436ed2c4cb MDL-77761 core_form: Add label for editor format selector 2023-03-29 08:09:54 +08:00
Andrew Nicols
cd48ae56c7 MDL-77559 js: Rebuild all JS with Node 16 2023-03-09 09:53:19 +08:00
Jun Pataleta
a377bf30c4 Merge branch 'MDL-75012-401-5' of https://github.com/andrewnicols/moodle into MOODLE_401_STABLE 2023-03-02 12:31:09 +08:00
Andrew Nicols
288620b0b4 MDL-75012 js: Full build of all grunt things 2023-03-02 12:15:25 +08:00
Paul Holden
1eed4bca84 MDL-77368 forms: remove console logging of upload DOM element. 2023-03-02 11:19:48 +08:00
Andrew Nicols
8c16eb18f6 Merge branch 'MDL-76478-password-unmask-MOODLE_401_STABLE' of https://github.com/brendanheywood/moodle into MOODLE_401_STABLE 2023-02-15 23:25:35 +08:00
Ilya Tregubov
946504b58d Merge branch 'MDL-75230-401' of https://github.com/andelacruz/moodle into MOODLE_401_STABLE 2023-02-15 16:12:50 +08:00
Angelia Dela Cruz
3b4246cd89 MDL-75230 behat: Lesson Behat tests optimised
Replace steps that manually add Lesson instances via the UI and use
Behat generators. This improves the speed of the Behat test runs.
2023-02-08 15:49:42 +08:00
Andrew Nicols
61f1700fbf Merge branch 'mdl-76729_401' of https://github.com/james-cnz/moodle into MOODLE_401_STABLE 2023-02-07 12:37:16 +08:00
Marina Glancy
2dd7290ccb MDL-76362 various: Avoid passing nulls to functions that don't allow nulls
PHP 8.1 is more strict on the parameter type. Functions such as trim(), strlen(), str_replace(), etc
show notice when null is passed as an argument
2023-01-23 09:16:06 +08:00
Jun Pataleta
8280476728 MDL-76803 lang: Update usages of reworded email display options 2023-01-10 16:01:44 +08:00
james-cnz
bc574f252d MDL-76729 filepicker: Restore file picker thumbnails in tree view 2023-01-10 12:01:27 +13:00
Paul Holden
0d20d1e8aa MDL-76667 forms: mark modal form as submitted upon success.
Ensure the form change checker module doesn't warn user about it.
2022-12-13 14:48:10 +00:00
Brendan Heywood
11721f7ff5 MDL-76478 formslib: Fix autocomplete bug of existing passwords 2022-12-06 12:34:25 +11:00
Marina Glancy
a5f92c041e MDL-74853 various: add second parameter to htmlentities functions
Default value of the $flag argument changed in PHP 8.1 from ENT_COMPAT to ENT_QUOTES | ENT_SUBSTITUTE
To ensure consistent behavior across different PHP version the second parameter is now required for the functions:
htmlspecialchars(), htmlentities(), htmlspecialchars_decode(), html_entity_decode() and get_html_translation_table()
2022-11-28 16:12:32 +01:00
Andrew Nicols
7e6d32d7c2 Merge branch 'MDL-76112-master' of https://github.com/marinaglancy/moodle 2022-11-16 10:07:49 +08:00
Sara Arjona
91e66dbaed Merge branch 'MDL-76039' of https://github.com/paulholden/moodle 2022-11-15 17:57:07 +01:00
Víctor Déniz
32fd6e60a4 Merge branch 'MDL-76229-master' of https://github.com/meirzamoodle/moodle 2022-11-14 22:56:13 +00:00
Paul Holden
7012900d08 MDL-76039 forms: account for null values in serialize util method.
Co-authored-by: Marina Glancy <marina@moodle.com>
2022-11-14 14:20:52 +00:00
Meirza
82d491cafa MDL-76229 core_form: Show frozen text editor in a more accessible way. 2022-11-12 18:27:09 +07:00
Sara Arjona
d1a0ee011f Merge branch 'MDL-76059' of https://github.com/paulholden/moodle 2022-11-09 12:31:31 +01:00
Marina Glancy
a34b4ebdc3 MDL-76112 various: can not pss null as 3rd param to preg_split
This produces notices in PHP 8.1
2022-10-28 10:51:20 +02:00
Thong Bui
5151cd6bd0 MDL-75784 Forms: Fix issues multi expand all/collapse buttons on a page 2022-10-26 14:06:54 +07:00
Paul Holden
3be5954500 MDL-76059 forms: graceful early exit for invalid button elements.
Ensure login form tries to capture guest button only if it exists.
2022-10-21 19:36:24 +01:00
Huong Nguyen
0795b579fa MDL-74814 forms: Fix accessibility issue in edit profile page
- Fixed legend tag issue
 - Modified the passwordunmask Javascript hide/unhide the password field by CSS class
2022-10-17 09:31:53 +07:00
Sara Arjona
fd14173a88 Merge branch 'MDL-75656' of https://github.com/paulholden/moodle 2022-10-10 16:16:20 +02:00
Jun Pataleta
6efeecd126 Merge branch 'MDL-75910-master' of https://github.com/andrewnicols/moodle 2022-10-10 11:07:27 +08:00
Andrew Nicols
1e71671205 Merge branch 'MDL-61395' of https://github.com/paulholden/moodle 2022-10-09 13:13:03 +08:00
Simey Lameze
f1be9b6544 MDL-75910 core_form: Allow editor field to set a hidden label
When an editor is used in a form as part of a group, it is missing its
label element.

This happens because there is no inline template for the editor, and
therefore it reverts to using the old `toHtml` function. The legacy
function does not cater to the editor being in a group, and therefore
does not add the hidden label.

In addition, the hiddenLabel attribute was missing from the editor
element. This is a semi-standard element but must be added to each
supporting element.

Both the missing inline template for the editor, and the hidden label
attribute must be present:
- If the hidden label attribute is not present, then the standard inline
  template will add a visible label within the group.
- If the inline editor template is missing, then the label is not shown
  at all.
2022-10-06 22:53:47 +08:00
Andrew Nicols
39241f20e0 MDL-71686 core_form: Include missing build 2022-10-06 14:43:55 +08:00
Andrew Nicols
f075272e69 MDL-71686 core_form: Move form serializer to shared function 2022-10-06 10:21:01 +08:00
Andrew Nicols
2423c26749 Merge branch 'MDL-71686-master' of https://github.com/marinaglancy/moodle 2022-10-06 10:20:56 +08:00
Paul Holden
a366cb4d5c MDL-61395 forms: style frozen tag element values. 2022-09-26 11:15:20 +01:00