From 6fb4aabcbaab2dc01f03e913876a834db0e19fdf Mon Sep 17 00:00:00 2001 From: Ilya Kantor Date: Tue, 2 Apr 2019 14:01:44 +0300 Subject: [PATCH] components --- .../8-sort-objects/solution.md | 7 +- .../05-array-methods/8-sort-objects/task.md | 9 +- .../12-mutation-observer/article.md | 0 {2-ui/99-misc => 10-misc}/index.md | 0 .../07-modifying-document/article.md | 70 +++- .../01-onload-ondomcontentloaded/article.md | 0 .../readystate.view/iframe.html | 0 .../readystate.view/index.html | 0 .../window-onbeforeunload.view/index.html | 0 .../02-script-async-defer/article.md | 0 .../02-script-async-defer/long.js | 0 .../02-script-async-defer/small.js | 0 .../window-onbeforeunload.view/index.html | 0 .../1-load-img-callback/solution.md | 0 .../solution.view/index.html | 0 .../source.view/index.html | 0 .../1-load-img-callback/task.md | 0 .../03-onload-onerror/article.md | 0 .../crossorigin.view/error.js | 0 2-ui/{10-loading => 5-loading}/index.md | 0 .../01-popup-windows/article.md | 0 .../03-cross-window-communication/article.md | 0 .../postmessage.view/iframe.html | 0 .../postmessage.view/index.html | 0 .../sandbox.view/index.html | 0 .../sandbox.view/sandboxed.html | 0 .../06-clickjacking/article.md | 0 .../clickjacking-visible.view/facebook.html | 0 .../clickjacking-visible.view/index.html | 0 .../clickjacking.view/facebook.html | 0 .../clickjacking.view/index.html | 0 .../protector.view/iframe.html | 0 .../06-clickjacking/protector.view/index.html | 0 .../top-location.view/iframe.html | 0 .../top-location.view/index.html | 0 .../index.md | 0 .../01-concat/_js.view/solution.js | 0 .../01-concat/_js.view/source.js | 0 .../01-concat/_js.view/test.js | 0 .../01-concat}/solution.md | 0 .../01-concat/task.md | 0 .../8bit-integer-256.png | Bin .../8bit-integer-256@2x.png | Bin .../8bit-integer-257.png | Bin .../8bit-integer-257@2x.png | Bin .../arraybuffer-view-buffersource.png | Bin .../arraybuffer-view-buffersource@2x.png | Bin .../arraybuffer-views.png | Bin .../arraybuffer-views@2x.png | Bin .../01-arraybuffer-binary-arrays/article.md | 0 .../02-text-decoder/article.md | 0 {6-binary => 4-binary}/03-blob/article.md | 0 {6-binary => 4-binary}/03-blob/blob.png | Bin {6-binary => 4-binary}/03-blob/blob@2x.png | Bin {6-binary => 4-binary}/04-file/article.md | 0 {6-binary => 4-binary}/index.md | 0 .../01-fetch-basics/article.md | 0 .../01-fetch-basics/logo-fetch.svg | 0 .../01-fetch-basics/post.view/server.js | 0 .../02-fetch-progress/article.md | 0 .../02-fetch-progress/logo-fetch.svg | 0 .../progress.view/index.html | 0 .../02-fetch-progress/progress.view/long.txt | 0 .../03-fetch-abort/article.md | 0 .../03-fetch-abort/demo.view/server.js | 0 .../1-do-we-need-origin/solution.md | 0 .../1-do-we-need-origin/task.md | 0 .../04-fetch-crossorigin/article.md | 0 .../cors-gmail-messages.png | Bin .../cors-gmail-messages@2x.png | Bin .../04-fetch-crossorigin/demo.view/index.html | 0 .../04-fetch-crossorigin/demo.view/server.js | 0 .../xhr-another-domain.png | Bin .../xhr-another-domain@2x.png | Bin .../04-fetch-crossorigin/xhr-preflight.png | Bin .../04-fetch-crossorigin/xhr-preflight@2x.png | Bin .../05-fetch-api/article.md | 0 .../05-fetch-api/logo-fetch.svg | 0 .../05-fetch-api/post.view/index.html | 0 .../05-fetch-api/post.view/server.js | 0 {7-network => 5-network}/06-url/article.md | 0 .../06-url/url-object.png | Bin .../06-url/url-object@2x.png | Bin .../07-xmlhttprequest/article.md | 0 .../07-xmlhttprequest/example.view/index.html | 0 .../07-xmlhttprequest/example.view/server.js | 0 .../07-xmlhttprequest/hello.txt | 0 .../phones-async.view/index.html | 0 .../phones-async.view/phones.json | 0 .../phones-async.view/server.js | 0 .../07-xmlhttprequest/phones.json | 0 .../07-xmlhttprequest/phones.view/index.html | 0 .../07-xmlhttprequest/phones.view/phones.json | 0 .../07-xmlhttprequest/phones.view/server.js | 0 .../07-xmlhttprequest/post.view/index.html | 0 .../07-xmlhttprequest/post.view/server.js | 0 .../08-websocket/article.md | 0 .../08-websocket/chat.view/index.html | 0 .../08-websocket/chat.view/server.js | 0 .../08-websocket/demo.view/server.js | 0 .../08-websocket/websocket-handshake.png | Bin .../08-websocket/websocket-handshake@2x.png | Bin 5-network/index.md | 2 + .../01-cookie/article.md | 0 .../01-cookie/cookie-third-party-2.png | Bin .../01-cookie/cookie-third-party-2@2x.png | Bin .../01-cookie/cookie-third-party-3.png | Bin .../01-cookie/cookie-third-party-3@2x.png | Bin .../01-cookie/cookie-third-party.png | Bin .../01-cookie/cookie-third-party@2x.png | Bin .../01-cookie/cookie-xsrf.png | Bin .../01-cookie/cookie-xsrf@2x.png | Bin .../01-cookie/cookie.js | 0 .../01-cookie/safari-nocookie.png | Bin .../01-cookie/safari-nocookie@2x.png | Bin .../1-form-autosave/solution.md | 0 .../1-form-autosave/solution.view/index.html | 0 .../1-form-autosave/source.view/index.html | 0 .../02-localstorage/1-form-autosave/task.md | 0 .../02-localstorage/article.md | 0 .../sessionstorage.view/iframe.html | 0 .../sessionstorage.view/index.html | 0 .../03-indexeddb/article.md | 0 .../03-indexeddb/books.view/index.html | 0 .../03-indexeddb/indexeddb-cursor.png | Bin .../03-indexeddb/indexeddb-cursor@2x.png | Bin .../03-indexeddb/indexeddb-index.png | Bin .../03-indexeddb/indexeddb-index@2x.png | Bin .../03-indexeddb/indexeddb-structure.png | Bin .../03-indexeddb/indexeddb-structure@2x.png | Bin .../index.md | 0 .../1-bezier-curve/article.md | 0 .../1-bezier-curve/bezier-car.png | Bin .../1-bezier-curve/bezier-car@2x.png | Bin .../1-bezier-curve/bezier-letter.png | Bin .../1-bezier-curve/bezier-letter@2x.png | Bin .../1-bezier-curve/bezier-vase.png | Bin .../1-bezier-curve/bezier-vase@2x.png | Bin .../1-bezier-curve/bezier2.png | Bin .../1-bezier-curve/bezier2@2x.png | Bin .../1-bezier-curve/bezier3-draw1.png | Bin .../1-bezier-curve/bezier3-draw1@2x.png | Bin .../1-bezier-curve/bezier3-draw2.png | Bin .../1-bezier-curve/bezier3-draw2@2x.png | Bin .../1-bezier-curve/bezier3-e.png | Bin .../1-bezier-curve/bezier3-e@2x.png | Bin .../1-bezier-curve/bezier3.png | Bin .../1-bezier-curve/bezier3@2x.png | Bin .../1-bezier-curve/bezier4-e.png | Bin .../1-bezier-curve/bezier4-e@2x.png | Bin .../1-bezier-curve/bezier4.png | Bin .../1-bezier-curve/bezier4@2x.png | Bin .../1-bezier-curve/demo.svg | 0 .../1-bezier-curve/pause.png | Bin .../1-bezier-curve/play.png | Bin .../1-animate-logo-css/solution.md | 0 .../solution.view/index.html | 0 .../1-animate-logo-css/source.view/index.html | 0 .../1-animate-logo-css/task.md | 0 .../2-animate-logo-bezier-css/bezier-up.png | Bin .../bezier-up@2x.png | Bin .../2-animate-logo-bezier-css/solution.md | 0 .../solution.view/index.html | 0 .../2-animate-logo-bezier-css/task.md | 0 .../3-animate-circle}/solution.md | 0 .../3-animate-circle/solution.view/index.html | 0 .../3-animate-circle/source.view/index.html | 0 .../2-css-animations/3-animate-circle/task.md | 0 .../2-css-animations/article.md | 0 .../2-css-animations/bezier-linear.png | Bin .../2-css-animations/bezier-linear@2x.png | Bin .../2-css-animations/bezier-train-over.png | Bin .../2-css-animations/bezier-train-over@2x.png | Bin .../2-css-animations/boat.view/index.html | 0 .../2-css-animations/boat.view/style.css | 0 .../digits-negative-delay.view/index.html | 0 .../digits-negative-delay.view/script.js | 0 .../digits-negative-delay.view/style.css | 0 .../2-css-animations/digits.view/index.html | 0 .../2-css-animations/digits.view/script.js | 0 .../2-css-animations/digits.view/style.css | 0 .../2-css-animations/ease-in-out.png | Bin .../2-css-animations/ease-in-out@2x.png | Bin .../2-css-animations/ease-in.png | Bin .../2-css-animations/ease-in@2x.png | Bin .../2-css-animations/ease-out.png | Bin .../2-css-animations/ease-out@2x.png | Bin .../2-css-animations/ease.png | Bin .../2-css-animations/ease@2x.png | Bin .../2-css-animations/step-end.view/index.html | 0 .../2-css-animations/step-end.view/style.css | 0 .../step-list.view/index.html | 0 .../2-css-animations/step-list.view/style.css | 0 .../2-css-animations/step.view/index.html | 0 .../2-css-animations/step.view/style.css | 0 .../2-css-animations/train-curve.png | Bin .../2-css-animations/train-curve@2x.png | Bin .../train-linear.view/index.html | 0 .../train-linear.view/style.css | 0 .../train-over.view/index.html | 0 .../train-over.view/style.css | 0 .../2-css-animations/train.view/index.html | 0 .../2-css-animations/train.view/style.css | 0 .../3-js-animation/1-animate-ball/solution.md | 0 .../1-animate-ball/solution.view/index.html | 0 .../1-animate-ball/solution.view/style.css | 0 .../1-animate-ball/source.view/index.html | 0 .../1-animate-ball/source.view/style.css | 0 .../3-js-animation/1-animate-ball/task.md | 0 .../2-animate-ball-hops/solution.md | 0 .../solution.view/index.html | 0 .../solution.view/style.css | 0 .../2-animate-ball-hops/task.md | 0 .../3-js-animation/article.md | 0 .../3-js-animation/back.png | Bin .../3-js-animation/back.view/index.html | 0 .../3-js-animation/back.view/style.css | 0 .../3-js-animation/back@2x.png | Bin .../3-js-animation/bezier-linear.png | Bin .../3-js-animation/bezier-linear@2x.png | Bin .../bounce-easeinout.view/index.html | 0 .../bounce-easeinout.view/style.css | 0 .../bounce-easeout.view/index.html | 0 .../bounce-easeout.view/style.css | 0 .../3-js-animation/bounce-inout.png | Bin .../3-js-animation/bounce-inout@2x.png | Bin .../3-js-animation/bounce.view/index.html | 0 .../3-js-animation/bounce.view/style.css | 0 .../3-js-animation/circ-ease.png | Bin .../3-js-animation/circ-ease@2x.png | Bin .../3-js-animation/circ.png | Bin .../3-js-animation/circ.view/index.html | 0 .../3-js-animation/circ.view/style.css | 0 .../3-js-animation/circ@2x.png | Bin .../3-js-animation/elastic.png | Bin .../3-js-animation/elastic.view/index.html | 0 .../3-js-animation/elastic.view/style.css | 0 .../3-js-animation/elastic@2x.png | Bin .../3-js-animation/linear.png | Bin .../3-js-animation/linear@2x.png | Bin .../3-js-animation/move-raf.view/index.html | 0 .../3-js-animation/move.view/index.html | 0 .../3-js-animation/quad.png | Bin .../3-js-animation/quad.view/index.html | 0 .../3-js-animation/quad.view/style.css | 0 .../3-js-animation/quad@2x.png | Bin .../3-js-animation/quint.png | Bin .../3-js-animation/quint.view/index.html | 0 .../3-js-animation/quint.view/style.css | 0 .../3-js-animation/quint@2x.png | Bin .../3-js-animation/text.view/index.html | 0 .../3-js-animation/text.view/style.css | 0 .../3-js-animation/width.view/animate.js | 0 .../3-js-animation/width.view/index.html | 0 {3-animation => 7-animation}/index.md | 0 7-network/index.md | 5 - .../1-webcomponents-intro/article.md | 1 + 8-web-components/2-custom-elements/article.md | 38 ++- 8-web-components/3-shadow-dom/article.md | 308 ++++-------------- .../article.md | 58 +++- .../5-slots-composition/article.md | 277 ++++++++++++---- .../6-shadow-dom-style/article.md | 108 +++--- .../7-shadow-dom-events/article.md | 192 +++++++++++ .../01-regexp-introduction/article.md | 0 .../02-regexp-methods/article.md | 0 .../1-find-time-hh-mm/solution.md | 0 .../1-find-time-hh-mm/task.md | 0 .../03-regexp-character-classes/article.md | 0 .../hello-java-boundaries.png | Bin .../hello-java-boundaries@2x.png | Bin .../love-html5-classes.png | Bin .../love-html5-classes@2x.png | Bin .../04-regexp-escaping/article.md | 0 .../1-find-range-1/solution.md | 0 .../1-find-range-1/task.md | 0 .../2-find-time-2-formats/solution.md | 0 .../2-find-time-2-formats/task.md | 0 .../article.md | 0 .../1-find-text-manydots/solution.md | 0 .../1-find-text-manydots/task.md | 0 .../2-find-html-colors-6hex/solution.md | 0 .../2-find-html-colors-6hex/task.md | 0 .../07-regexp-quantifiers/article.md | 0 .../1-lazy-greedy/solution.md | 0 .../1-lazy-greedy/task.md | 0 .../3-find-html-comments/solution.md | 0 .../3-find-html-comments/task.md | 0 .../4-find-html-tags-greedy-lazy/solution.md | 0 .../4-find-html-tags-greedy-lazy/task.md | 0 .../08-regexp-greedy-and-lazy/article.md | 0 .../witch_greedy1.png | Bin .../witch_greedy1@2x.png | Bin .../witch_greedy2.png | Bin .../witch_greedy2@2x.png | Bin .../witch_greedy3.png | Bin .../witch_greedy3@2x.png | Bin .../witch_greedy4.png | Bin .../witch_greedy4@2x.png | Bin .../witch_greedy5.png | Bin .../witch_greedy5@2x.png | Bin .../witch_greedy6.png | Bin .../witch_greedy6@2x.png | Bin .../08-regexp-greedy-and-lazy/witch_lazy3.png | Bin .../witch_lazy3@2x.png | Bin .../08-regexp-greedy-and-lazy/witch_lazy4.png | Bin .../witch_lazy4@2x.png | Bin .../08-regexp-greedy-and-lazy/witch_lazy5.png | Bin .../witch_lazy5@2x.png | Bin .../08-regexp-greedy-and-lazy/witch_lazy6.png | Bin .../witch_lazy6@2x.png | Bin .../1-find-webcolor-3-or-6/solution.md | 0 .../1-find-webcolor-3-or-6/task.md | 0 .../solution.md | 0 .../3-find-decimal-positive-numbers/task.md | 0 .../4-find-decimal-numbers/solution.md | 0 .../4-find-decimal-numbers/task.md | 0 .../5-parse-expression/solution.md | 0 .../5-parse-expression/task.md | 0 .../09-regexp-groups/article.md | 0 .../09-regexp-groups/regexp-nested-groups.png | Bin .../regexp-nested-groups@2x.png | Bin .../10-regexp-backreferences/article.md | 0 .../01-find-programming-language/solution.md | 0 .../01-find-programming-language/task.md | 0 .../02-find-matching-bbtags/solution.md | 0 .../02-find-matching-bbtags/task.md | 0 .../03-match-quoted-string/solution.md | 0 .../03-match-quoted-string/task.md | 0 .../04-match-exact-tag/solution.md | 0 .../04-match-exact-tag/task.md | 0 .../11-regexp-alternation/article.md | 0 .../12-regexp-anchors/1-start-end/solution.md | 0 .../12-regexp-anchors/1-start-end/task.md | 0 .../12-regexp-anchors/2-test-mac/solution.md | 0 .../12-regexp-anchors/2-test-mac/task.md | 0 .../12-regexp-anchors/article.md | 0 .../13-regexp-multiline-mode/article.md | 0 .../14-regexp-lookahead-lookbehind/article.md | 0 .../article.md | 0 .../20-regexp-unicode/article.md | 0 .../21-regexp-unicode-properties/article.md | 0 .../22-regexp-sticky/article.md | 0 .../index.md | 0 figures.sketch | Bin 4845041 -> 4844769 bytes 344 files changed, 669 insertions(+), 406 deletions(-) rename {2-ui/99-misc => 10-misc}/12-mutation-observer/article.md (100%) rename {2-ui/99-misc => 10-misc}/index.md (100%) rename 2-ui/{10-loading => 5-loading}/01-onload-ondomcontentloaded/article.md (100%) rename 2-ui/{10-loading => 5-loading}/01-onload-ondomcontentloaded/readystate.view/iframe.html (100%) rename 2-ui/{10-loading => 5-loading}/01-onload-ondomcontentloaded/readystate.view/index.html (100%) rename 2-ui/{10-loading => 5-loading}/01-onload-ondomcontentloaded/window-onbeforeunload.view/index.html (100%) rename 2-ui/{10-loading => 5-loading}/02-script-async-defer/article.md (100%) rename 2-ui/{10-loading => 5-loading}/02-script-async-defer/long.js (100%) rename 2-ui/{10-loading => 5-loading}/02-script-async-defer/small.js (100%) rename 2-ui/{10-loading => 5-loading}/02-script-async-defer/window-onbeforeunload.view/index.html (100%) rename 2-ui/{10-loading => 5-loading}/03-onload-onerror/1-load-img-callback/solution.md (100%) rename 2-ui/{10-loading => 5-loading}/03-onload-onerror/1-load-img-callback/solution.view/index.html (100%) rename 2-ui/{10-loading => 5-loading}/03-onload-onerror/1-load-img-callback/source.view/index.html (100%) rename 2-ui/{10-loading => 5-loading}/03-onload-onerror/1-load-img-callback/task.md (100%) rename 2-ui/{10-loading => 5-loading}/03-onload-onerror/article.md (100%) rename 2-ui/{10-loading => 5-loading}/03-onload-onerror/crossorigin.view/error.js (100%) rename 2-ui/{10-loading => 5-loading}/index.md (100%) rename {4-frames-and-windows => 3-frames-and-windows}/01-popup-windows/article.md (100%) rename {4-frames-and-windows => 3-frames-and-windows}/03-cross-window-communication/article.md (100%) rename {4-frames-and-windows => 3-frames-and-windows}/03-cross-window-communication/postmessage.view/iframe.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/03-cross-window-communication/postmessage.view/index.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/03-cross-window-communication/sandbox.view/index.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/03-cross-window-communication/sandbox.view/sandboxed.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/06-clickjacking/article.md (100%) rename {4-frames-and-windows => 3-frames-and-windows}/06-clickjacking/clickjacking-visible.view/facebook.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/06-clickjacking/clickjacking-visible.view/index.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/06-clickjacking/clickjacking.view/facebook.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/06-clickjacking/clickjacking.view/index.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/06-clickjacking/protector.view/iframe.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/06-clickjacking/protector.view/index.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/06-clickjacking/top-location.view/iframe.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/06-clickjacking/top-location.view/index.html (100%) rename {4-frames-and-windows => 3-frames-and-windows}/index.md (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/01-concat/_js.view/solution.js (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/01-concat/_js.view/source.js (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/01-concat/_js.view/test.js (100%) rename {3-animation/2-css-animations/3-animate-circle => 4-binary/01-arraybuffer-binary-arrays/01-concat}/solution.md (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/01-concat/task.md (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/8bit-integer-256.png (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/8bit-integer-256@2x.png (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/8bit-integer-257.png (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/8bit-integer-257@2x.png (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/arraybuffer-view-buffersource.png (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/arraybuffer-view-buffersource@2x.png (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/arraybuffer-views.png (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/arraybuffer-views@2x.png (100%) rename {6-binary => 4-binary}/01-arraybuffer-binary-arrays/article.md (100%) rename {6-binary => 4-binary}/02-text-decoder/article.md (100%) rename {6-binary => 4-binary}/03-blob/article.md (100%) rename {6-binary => 4-binary}/03-blob/blob.png (100%) rename {6-binary => 4-binary}/03-blob/blob@2x.png (100%) rename {6-binary => 4-binary}/04-file/article.md (100%) rename {6-binary => 4-binary}/index.md (100%) rename {7-network => 5-network}/01-fetch-basics/article.md (100%) rename {7-network => 5-network}/01-fetch-basics/logo-fetch.svg (100%) rename {7-network => 5-network}/01-fetch-basics/post.view/server.js (100%) rename {7-network => 5-network}/02-fetch-progress/article.md (100%) rename {7-network => 5-network}/02-fetch-progress/logo-fetch.svg (100%) rename {7-network => 5-network}/02-fetch-progress/progress.view/index.html (100%) rename {7-network => 5-network}/02-fetch-progress/progress.view/long.txt (100%) rename {7-network => 5-network}/03-fetch-abort/article.md (100%) rename {7-network => 5-network}/03-fetch-abort/demo.view/server.js (100%) rename {7-network => 5-network}/04-fetch-crossorigin/1-do-we-need-origin/solution.md (100%) rename {7-network => 5-network}/04-fetch-crossorigin/1-do-we-need-origin/task.md (100%) rename {7-network => 5-network}/04-fetch-crossorigin/article.md (100%) rename {7-network => 5-network}/04-fetch-crossorigin/cors-gmail-messages.png (100%) rename {7-network => 5-network}/04-fetch-crossorigin/cors-gmail-messages@2x.png (100%) rename {7-network => 5-network}/04-fetch-crossorigin/demo.view/index.html (100%) rename {7-network => 5-network}/04-fetch-crossorigin/demo.view/server.js (100%) rename {7-network => 5-network}/04-fetch-crossorigin/xhr-another-domain.png (100%) rename {7-network => 5-network}/04-fetch-crossorigin/xhr-another-domain@2x.png (100%) rename {7-network => 5-network}/04-fetch-crossorigin/xhr-preflight.png (100%) rename {7-network => 5-network}/04-fetch-crossorigin/xhr-preflight@2x.png (100%) rename {7-network => 5-network}/05-fetch-api/article.md (100%) rename {7-network => 5-network}/05-fetch-api/logo-fetch.svg (100%) rename {7-network => 5-network}/05-fetch-api/post.view/index.html (100%) rename {7-network => 5-network}/05-fetch-api/post.view/server.js (100%) rename {7-network => 5-network}/06-url/article.md (100%) rename {7-network => 5-network}/06-url/url-object.png (100%) rename {7-network => 5-network}/06-url/url-object@2x.png (100%) rename {7-network => 5-network}/07-xmlhttprequest/article.md (100%) rename {7-network => 5-network}/07-xmlhttprequest/example.view/index.html (100%) rename {7-network => 5-network}/07-xmlhttprequest/example.view/server.js (100%) rename {7-network => 5-network}/07-xmlhttprequest/hello.txt (100%) rename {7-network => 5-network}/07-xmlhttprequest/phones-async.view/index.html (100%) rename {7-network => 5-network}/07-xmlhttprequest/phones-async.view/phones.json (100%) rename {7-network => 5-network}/07-xmlhttprequest/phones-async.view/server.js (100%) rename {7-network => 5-network}/07-xmlhttprequest/phones.json (100%) rename {7-network => 5-network}/07-xmlhttprequest/phones.view/index.html (100%) rename {7-network => 5-network}/07-xmlhttprequest/phones.view/phones.json (100%) rename {7-network => 5-network}/07-xmlhttprequest/phones.view/server.js (100%) rename {7-network => 5-network}/07-xmlhttprequest/post.view/index.html (100%) rename {7-network => 5-network}/07-xmlhttprequest/post.view/server.js (100%) rename {7-network => 5-network}/08-websocket/article.md (100%) rename {7-network => 5-network}/08-websocket/chat.view/index.html (100%) rename {7-network => 5-network}/08-websocket/chat.view/server.js (100%) rename {7-network => 5-network}/08-websocket/demo.view/server.js (100%) rename {7-network => 5-network}/08-websocket/websocket-handshake.png (100%) rename {7-network => 5-network}/08-websocket/websocket-handshake@2x.png (100%) create mode 100644 5-network/index.md rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/article.md (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/cookie-third-party-2.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/cookie-third-party-2@2x.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/cookie-third-party-3.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/cookie-third-party-3@2x.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/cookie-third-party.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/cookie-third-party@2x.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/cookie-xsrf.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/cookie-xsrf@2x.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/cookie.js (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/safari-nocookie.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/01-cookie/safari-nocookie@2x.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/02-localstorage/1-form-autosave/solution.md (100%) rename {2-ui/20-data-storage => 6-data-storage}/02-localstorage/1-form-autosave/solution.view/index.html (100%) rename {2-ui/20-data-storage => 6-data-storage}/02-localstorage/1-form-autosave/source.view/index.html (100%) rename {2-ui/20-data-storage => 6-data-storage}/02-localstorage/1-form-autosave/task.md (100%) rename {2-ui/20-data-storage => 6-data-storage}/02-localstorage/article.md (100%) rename {2-ui/20-data-storage => 6-data-storage}/02-localstorage/sessionstorage.view/iframe.html (100%) rename {2-ui/20-data-storage => 6-data-storage}/02-localstorage/sessionstorage.view/index.html (100%) rename {2-ui/20-data-storage => 6-data-storage}/03-indexeddb/article.md (100%) rename {2-ui/20-data-storage => 6-data-storage}/03-indexeddb/books.view/index.html (100%) rename {2-ui/20-data-storage => 6-data-storage}/03-indexeddb/indexeddb-cursor.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/03-indexeddb/indexeddb-cursor@2x.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/03-indexeddb/indexeddb-index.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/03-indexeddb/indexeddb-index@2x.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/03-indexeddb/indexeddb-structure.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/03-indexeddb/indexeddb-structure@2x.png (100%) rename {2-ui/20-data-storage => 6-data-storage}/index.md (100%) rename {3-animation => 7-animation}/1-bezier-curve/article.md (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier-car.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier-car@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier-letter.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier-letter@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier-vase.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier-vase@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier2.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier2@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier3-draw1.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier3-draw1@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier3-draw2.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier3-draw2@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier3-e.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier3-e@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier3.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier3@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier4-e.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier4-e@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier4.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/bezier4@2x.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/demo.svg (100%) rename {3-animation => 7-animation}/1-bezier-curve/pause.png (100%) rename {3-animation => 7-animation}/1-bezier-curve/play.png (100%) rename {3-animation => 7-animation}/2-css-animations/1-animate-logo-css/solution.md (100%) rename {3-animation => 7-animation}/2-css-animations/1-animate-logo-css/solution.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/1-animate-logo-css/source.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/1-animate-logo-css/task.md (100%) rename {3-animation => 7-animation}/2-css-animations/2-animate-logo-bezier-css/bezier-up.png (100%) rename {3-animation => 7-animation}/2-css-animations/2-animate-logo-bezier-css/bezier-up@2x.png (100%) rename {3-animation => 7-animation}/2-css-animations/2-animate-logo-bezier-css/solution.md (100%) rename {3-animation => 7-animation}/2-css-animations/2-animate-logo-bezier-css/solution.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/2-animate-logo-bezier-css/task.md (100%) rename {6-binary/01-arraybuffer-binary-arrays/01-concat => 7-animation/2-css-animations/3-animate-circle}/solution.md (100%) rename {3-animation => 7-animation}/2-css-animations/3-animate-circle/solution.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/3-animate-circle/source.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/3-animate-circle/task.md (100%) rename {3-animation => 7-animation}/2-css-animations/article.md (100%) rename {3-animation => 7-animation}/2-css-animations/bezier-linear.png (100%) rename {3-animation => 7-animation}/2-css-animations/bezier-linear@2x.png (100%) rename {3-animation => 7-animation}/2-css-animations/bezier-train-over.png (100%) rename {3-animation => 7-animation}/2-css-animations/bezier-train-over@2x.png (100%) rename {3-animation => 7-animation}/2-css-animations/boat.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/boat.view/style.css (100%) rename {3-animation => 7-animation}/2-css-animations/digits-negative-delay.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/digits-negative-delay.view/script.js (100%) rename {3-animation => 7-animation}/2-css-animations/digits-negative-delay.view/style.css (100%) rename {3-animation => 7-animation}/2-css-animations/digits.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/digits.view/script.js (100%) rename {3-animation => 7-animation}/2-css-animations/digits.view/style.css (100%) rename {3-animation => 7-animation}/2-css-animations/ease-in-out.png (100%) rename {3-animation => 7-animation}/2-css-animations/ease-in-out@2x.png (100%) rename {3-animation => 7-animation}/2-css-animations/ease-in.png (100%) rename {3-animation => 7-animation}/2-css-animations/ease-in@2x.png (100%) rename {3-animation => 7-animation}/2-css-animations/ease-out.png (100%) rename {3-animation => 7-animation}/2-css-animations/ease-out@2x.png (100%) rename {3-animation => 7-animation}/2-css-animations/ease.png (100%) rename {3-animation => 7-animation}/2-css-animations/ease@2x.png (100%) rename {3-animation => 7-animation}/2-css-animations/step-end.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/step-end.view/style.css (100%) rename {3-animation => 7-animation}/2-css-animations/step-list.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/step-list.view/style.css (100%) rename {3-animation => 7-animation}/2-css-animations/step.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/step.view/style.css (100%) rename {3-animation => 7-animation}/2-css-animations/train-curve.png (100%) rename {3-animation => 7-animation}/2-css-animations/train-curve@2x.png (100%) rename {3-animation => 7-animation}/2-css-animations/train-linear.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/train-linear.view/style.css (100%) rename {3-animation => 7-animation}/2-css-animations/train-over.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/train-over.view/style.css (100%) rename {3-animation => 7-animation}/2-css-animations/train.view/index.html (100%) rename {3-animation => 7-animation}/2-css-animations/train.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/1-animate-ball/solution.md (100%) rename {3-animation => 7-animation}/3-js-animation/1-animate-ball/solution.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/1-animate-ball/solution.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/1-animate-ball/source.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/1-animate-ball/source.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/1-animate-ball/task.md (100%) rename {3-animation => 7-animation}/3-js-animation/2-animate-ball-hops/solution.md (100%) rename {3-animation => 7-animation}/3-js-animation/2-animate-ball-hops/solution.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/2-animate-ball-hops/solution.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/2-animate-ball-hops/task.md (100%) rename {3-animation => 7-animation}/3-js-animation/article.md (100%) rename {3-animation => 7-animation}/3-js-animation/back.png (100%) rename {3-animation => 7-animation}/3-js-animation/back.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/back.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/back@2x.png (100%) rename {3-animation => 7-animation}/3-js-animation/bezier-linear.png (100%) rename {3-animation => 7-animation}/3-js-animation/bezier-linear@2x.png (100%) rename {3-animation => 7-animation}/3-js-animation/bounce-easeinout.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/bounce-easeinout.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/bounce-easeout.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/bounce-easeout.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/bounce-inout.png (100%) rename {3-animation => 7-animation}/3-js-animation/bounce-inout@2x.png (100%) rename {3-animation => 7-animation}/3-js-animation/bounce.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/bounce.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/circ-ease.png (100%) rename {3-animation => 7-animation}/3-js-animation/circ-ease@2x.png (100%) rename {3-animation => 7-animation}/3-js-animation/circ.png (100%) rename {3-animation => 7-animation}/3-js-animation/circ.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/circ.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/circ@2x.png (100%) rename {3-animation => 7-animation}/3-js-animation/elastic.png (100%) rename {3-animation => 7-animation}/3-js-animation/elastic.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/elastic.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/elastic@2x.png (100%) rename {3-animation => 7-animation}/3-js-animation/linear.png (100%) rename {3-animation => 7-animation}/3-js-animation/linear@2x.png (100%) rename {3-animation => 7-animation}/3-js-animation/move-raf.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/move.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/quad.png (100%) rename {3-animation => 7-animation}/3-js-animation/quad.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/quad.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/quad@2x.png (100%) rename {3-animation => 7-animation}/3-js-animation/quint.png (100%) rename {3-animation => 7-animation}/3-js-animation/quint.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/quint.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/quint@2x.png (100%) rename {3-animation => 7-animation}/3-js-animation/text.view/index.html (100%) rename {3-animation => 7-animation}/3-js-animation/text.view/style.css (100%) rename {3-animation => 7-animation}/3-js-animation/width.view/animate.js (100%) rename {3-animation => 7-animation}/3-js-animation/width.view/index.html (100%) rename {3-animation => 7-animation}/index.md (100%) delete mode 100644 7-network/index.md rename 8-web-components/{4-template-tag => 4-template-element}/article.md (60%) create mode 100644 8-web-components/7-shadow-dom-events/article.md rename {5-regular-expressions => 9-regular-expressions}/01-regexp-introduction/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/02-regexp-methods/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/03-regexp-character-classes/1-find-time-hh-mm/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/03-regexp-character-classes/1-find-time-hh-mm/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/03-regexp-character-classes/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/03-regexp-character-classes/hello-java-boundaries.png (100%) rename {5-regular-expressions => 9-regular-expressions}/03-regexp-character-classes/hello-java-boundaries@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/03-regexp-character-classes/love-html5-classes.png (100%) rename {5-regular-expressions => 9-regular-expressions}/03-regexp-character-classes/love-html5-classes@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/04-regexp-escaping/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/05-regexp-character-sets-and-ranges/1-find-range-1/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/05-regexp-character-sets-and-ranges/1-find-range-1/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/05-regexp-character-sets-and-ranges/2-find-time-2-formats/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/05-regexp-character-sets-and-ranges/2-find-time-2-formats/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/05-regexp-character-sets-and-ranges/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/07-regexp-quantifiers/1-find-text-manydots/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/07-regexp-quantifiers/1-find-text-manydots/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/07-regexp-quantifiers/2-find-html-colors-6hex/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/07-regexp-quantifiers/2-find-html-colors-6hex/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/07-regexp-quantifiers/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/1-lazy-greedy/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/1-lazy-greedy/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/3-find-html-comments/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/3-find-html-comments/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/4-find-html-tags-greedy-lazy/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/4-find-html-tags-greedy-lazy/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy1.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy1@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy2.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy2@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy3.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy3@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy4.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy4@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy5.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy5@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy6.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_greedy6@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_lazy3.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_lazy3@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_lazy4.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_lazy4@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_lazy5.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_lazy5@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_lazy6.png (100%) rename {5-regular-expressions => 9-regular-expressions}/08-regexp-greedy-and-lazy/witch_lazy6@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/1-find-webcolor-3-or-6/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/1-find-webcolor-3-or-6/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/3-find-decimal-positive-numbers/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/3-find-decimal-positive-numbers/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/4-find-decimal-numbers/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/4-find-decimal-numbers/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/5-parse-expression/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/5-parse-expression/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/regexp-nested-groups.png (100%) rename {5-regular-expressions => 9-regular-expressions}/09-regexp-groups/regexp-nested-groups@2x.png (100%) rename {5-regular-expressions => 9-regular-expressions}/10-regexp-backreferences/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/11-regexp-alternation/01-find-programming-language/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/11-regexp-alternation/01-find-programming-language/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/11-regexp-alternation/02-find-matching-bbtags/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/11-regexp-alternation/02-find-matching-bbtags/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/11-regexp-alternation/03-match-quoted-string/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/11-regexp-alternation/03-match-quoted-string/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/11-regexp-alternation/04-match-exact-tag/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/11-regexp-alternation/04-match-exact-tag/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/11-regexp-alternation/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/12-regexp-anchors/1-start-end/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/12-regexp-anchors/1-start-end/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/12-regexp-anchors/2-test-mac/solution.md (100%) rename {5-regular-expressions => 9-regular-expressions}/12-regexp-anchors/2-test-mac/task.md (100%) rename {5-regular-expressions => 9-regular-expressions}/12-regexp-anchors/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/13-regexp-multiline-mode/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/14-regexp-lookahead-lookbehind/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/15-regexp-infinite-backtracking-problem/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/20-regexp-unicode/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/21-regexp-unicode-properties/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/22-regexp-sticky/article.md (100%) rename {5-regular-expressions => 9-regular-expressions}/index.md (100%) diff --git a/1-js/05-data-types/05-array-methods/8-sort-objects/solution.md b/1-js/05-data-types/05-array-methods/8-sort-objects/solution.md index f5684a6d..9f1ade70 100644 --- a/1-js/05-data-types/05-array-methods/8-sort-objects/solution.md +++ b/1-js/05-data-types/05-array-methods/8-sort-objects/solution.md @@ -1,5 +1,5 @@ ```js run no-beautify -function sortByName(arr) { +function sortByAge(arr) { arr.sort((a, b) => a.age > b.age ? 1 : -1); } @@ -7,11 +7,12 @@ let john = { name: "John", age: 25 }; let pete = { name: "Pete", age: 30 }; let mary = { name: "Mary", age: 28 }; -let arr = [ john, pete, mary ]; +let arr = [ pete, john, mary ]; -sortByName(arr); +sortByAge(arr); // now sorted is: [john, mary, pete] alert(arr[0].name); // John +alert(arr[1].name); // Mary alert(arr[2].name); // Pete ``` diff --git a/1-js/05-data-types/05-array-methods/8-sort-objects/task.md b/1-js/05-data-types/05-array-methods/8-sort-objects/task.md index fae6bcbe..9a215c9f 100644 --- a/1-js/05-data-types/05-array-methods/8-sort-objects/task.md +++ b/1-js/05-data-types/05-array-methods/8-sort-objects/task.md @@ -2,9 +2,9 @@ importance: 5 --- -# Sort objects +# Sort users by age -Write the function `sortByName(users)` that gets an array of objects with the `age` property and sorts them by `age`. +Write the function `sortByAge(users)` that gets an array of objects with the `age` property and sorts them by `age`. For instance: @@ -13,11 +13,12 @@ let john = { name: "John", age: 25 }; let pete = { name: "Pete", age: 30 }; let mary = { name: "Mary", age: 28 }; -let arr = [ john, pete, mary ]; +let arr = [ pete, john, mary ]; -sortByName(arr); +sortByAge(arr); // now: [john, mary, pete] alert(arr[0].name); // John +alert(arr[1].name); // Mary alert(arr[2].name); // Pete ``` diff --git a/2-ui/99-misc/12-mutation-observer/article.md b/10-misc/12-mutation-observer/article.md similarity index 100% rename from 2-ui/99-misc/12-mutation-observer/article.md rename to 10-misc/12-mutation-observer/article.md diff --git a/2-ui/99-misc/index.md b/10-misc/index.md similarity index 100% rename from 2-ui/99-misc/index.md rename to 10-misc/index.md diff --git a/2-ui/1-document/07-modifying-document/article.md b/2-ui/1-document/07-modifying-document/article.md index 22907554..16aacb45 100644 --- a/2-ui/1-document/07-modifying-document/article.md +++ b/2-ui/1-document/07-modifying-document/article.md @@ -136,7 +136,7 @@ Here's a brief list of methods to insert a node into a parent element (`parentEl ``` To insert `newLi` as the first element, we can do it like this: - + ```js list.insertBefore(newLi, list.firstChild); ``` @@ -335,6 +335,74 @@ An example of copying the message: ``` + +## DocumentFragment [#document-fragment] + +`DocumentFragment` is a special DOM node that serves as a wrapper to pass around groups of nodes. + +We can append other nodes to it, but when we insert it somewhere, then it "disappears", leaving its content inserted instead. + +For example, `getListContent` below generates a fragment with `
  • ` items, that are later inserted into `