{"id":17705,"date":"2023-03-17T08:51:15","date_gmt":"2023-03-17T08:51:15","guid":{"rendered":"https:\/\/soloweb.com.br\/blog\/?p=17705"},"modified":"2023-04-02T15:28:46","modified_gmt":"2023-04-02T15:28:46","slug":"construindo-um-componente-html-collapse-sem-usar-javascript","status":"publish","type":"post","link":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/","title":{"rendered":"Construindo um componente HTML collapse sem usar JavaScript"},"content":{"rendered":"\n<p>Na dica de hoje, vamos ensinar como fazer um collapse para seus sites usando apenas HTML e CSS.<\/p>\n\n\n\n<p>O collapse \u00e9 uma fun\u00e7\u00e3o para expandir e ocultar um elemento em um clique.  Fun\u00e7\u00e3o criada para estilizar uma lista e compactar mais informa\u00e7\u00f5es.<\/p>\n\n\n\n<p>Para criar essa fun\u00e7\u00e3o \u00e9 usada apenas 2 tags(details e summary) neste tutorial vamos ensinar de forma simples como usar e como estilizar esta fun\u00e7\u00e3o.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Passo 1<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;html&gt;\n    \n&lt;body&gt;    \n&lt;details class=\"collapse\"&gt;\n  &lt;summary class=\"titulo-exemplo\"&gt;Titulo&lt;\/summary&gt;\n  &lt;div class=\"descricao\"&gt;Lorem ipsum lo lar laoraLorem ipsum lo &lt;br&gt;\n                    lar laoraLorem ipsum lo lar laoraLorem ipsum &lt;br&gt;\n   lo lar laoraLorem ipsum lo lar laoraLorem ipsum lo lar laora&lt;\/div&gt;\n&lt;\/details&gt;\n\n\n&lt;\/body&gt;\n&lt;\/html&gt;<\/code><\/pre>\n\n\n\n<p>No exemplo acima j\u00e1 estamos com a fun\u00e7\u00e3o collapse funcionando. Temos a tag principal &#8220;details&#8221; depois a tag que ficar\u00e1 com o t\u00edtulo a &#8220;summary&#8221; e por \u00faltimo a tag com o conte\u00fado, que pode ser uma tag &#8220;div&#8221; ou &#8220;p&#8221;. Agora que a tag esta criada podemos estilizar sua fun\u00e7\u00e3o.<\/p>\n\n\n\n<figure class=\"wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-1 is-layout-flex wp-block-gallery-is-layout-flex\">\n<figure class=\"wp-block-image size-large is-style-default\"><img loading=\"lazy\" decoding=\"async\" width=\"435\" height=\"279\" data-id=\"17707\" src=\"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-11-09-11-1.png\" alt=\"\" class=\"wp-image-17707\" srcset=\"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-11-09-11-1.png 435w, https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-11-09-11-1-300x192.png 300w, https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-11-09-11-1-150x96.png 150w\" sizes=\"auto, (max-width: 435px) 100vw, 435px\" \/><\/figure>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"376\" height=\"254\" data-id=\"17708\" src=\"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-11-09-21.png\" alt=\"\" class=\"wp-image-17708\" srcset=\"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-11-09-21.png 376w, https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-11-09-21-300x203.png 300w, https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-11-09-21-150x101.png 150w\" sizes=\"auto, (max-width: 376px) 100vw, 376px\" \/><\/figure>\n<\/figure>\n\n\n\n<p>Veja o link abaixo para saber como montar um servidor simples para seus projetos:<\/p>\n\n\n\n<figure class=\"wp-block-embed aligncenter is-type-wp-embed is-provider-soloweb-tecnologia wp-block-embed-soloweb-tecnologia\"><div class=\"wp-block-embed__wrapper\">\n<blockquote class=\"wp-embedded-content\" data-secret=\"tZmvP250sE\"><a href=\"https:\/\/soloweb.com.br\/blog\/2023\/03\/09\/como-instalar-o-lamp-em-seu-ubuntu\/\">Como instalar o LAMP em seu Ubuntu<\/a><\/blockquote><iframe loading=\"lazy\" class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; clip: rect(1px, 1px, 1px, 1px);\" title=\"&#8220;Como instalar o LAMP em seu Ubuntu&#8221; &#8212; SOLOWEB Tecnologia\" src=\"https:\/\/soloweb.com.br\/blog\/2023\/03\/09\/como-instalar-o-lamp-em-seu-ubuntu\/embed\/#?secret=3GIJip6kiP#?secret=tZmvP250sE\" data-secret=\"tZmvP250sE\" width=\"600\" height=\"338\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe>\n<\/div><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Passo 2<\/h3>\n\n\n\n<p>Com os elementos inseridos vamos para parte do css, voc\u00ea pode criar um arquivo (style.css) ou pode abrir uma tag dentro do html &#8220;style&#8221; vamos aqui usar o exemplo da tag:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;html&gt;\n    &lt;style&gt;\nbody {\n  font-family: 'Open Sans', sans-serif;\n  font-size: 16px;\n}\n        \n        \n    &lt;\/style&gt;\n&lt;body&gt;    \n&lt;details class=\"collapse\"&gt;\n  &lt;summary class=\"titulo-exemplo\"&gt;Titulo&lt;\/summary&gt;\n  &lt;div class=\"description\"&gt;Lorem ipsum lo lar laoraLorem ipsum lo &lt;br&gt;\n                    lar laoraLorem ipsum lo lar laoraLorem ipsum &lt;br&gt;\n   lo lar laoraLorem ipsum lo lar laoraLorem ipsum lo lar laora&lt;\/div&gt;\n&lt;\/details&gt;\n\n\n&lt;\/body&gt;\n&lt;\/html&gt;<\/code><\/pre>\n\n\n\n<p>Adicionamos uma fonte maior no body da p\u00e1gina e mudamos a fonte, isso acima \u00e9 s\u00f3 um exemplo de como inserir css dentro do html, agora vamos estilizar nosso elemento.<\/p>\n\n\n\n<p>Dentro da tag &#8220;style&#8221; adicione o seguinte conte\u00fado:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>summary {\n    list-style: none;\n}  <\/code><\/pre>\n\n\n\n<p>Ele vai tirar as setas padr\u00f5es que fica do lado do t\u00edtulo, para voc\u00ea que n\u00e3o gostou daquela seta pode remover com esse css acima.<\/p>\n\n\n\n<p>Agora vamos personalizar mais um pouco:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>.collapse {\n  border: solid 1px gray;\n  border-radius: 4px;\n  box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.25);\n  margin-left: auto;\n  margin-right: auto;\n  max-width: 500px;\n  transition: background-color 0.25s;\n  will-change: background-color;\n\n  &amp;:first-child {\n    margin-top: 24px;\n  }\n\n  &amp;:not(:last-child) {\n    margin-bottom: 24px;\n  }\n\n  &amp;:hover {\n    background-color: red;\n  }\n}<\/code><\/pre>\n\n\n\n<p>Em resumo no css acima adicionei uma borda no conte\u00fado juntamente com cores e transi\u00e7\u00f5es dessas cores no background e tamb\u00e9m um efeito de bordar com sombreado.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>.titulo-exemplo {\n  cursor: pointer;\n  font-weight: 600;\n  padding: 50px;\n  position: relative;\n}<\/code><\/pre>\n\n\n\n<p>Por \u00faltimo, estilizei o summary mudando o cursor do mouse ao passar por cima do collapse.<\/p>\n\n\n\n<p>Voc\u00ea tem muito mais op\u00e7\u00f5es de estilos que pode ser feita no css com esse elemento. O intuito desse tutorial \u00e9 simplificar o m\u00e1ximo esse elemento que antes realiz\u00e1vamos com v\u00e1rias linhas de c\u00f3digo.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"614\" height=\"209\" src=\"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-14-32-46.png\" alt=\"\" class=\"wp-image-17709\" srcset=\"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-14-32-46.png 614w, https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-14-32-46-300x102.png 300w, https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/Captura-de-tela-de-2023-03-16-14-32-46-150x51.png 150w\" sizes=\"auto, (max-width: 614px) 100vw, 614px\" \/><\/figure>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Na dica de hoje, vamos ensinar como fazer um collapse para seus sites usando apenas HTML e CSS. O collapse<\/p>\n","protected":false},"author":5,"featured_media":17715,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"colormag_page_container_layout":"default_layout","colormag_page_sidebar_layout":"default_layout","_editorskit_title_hidden":false,"_editorskit_reading_time":0,"_editorskit_is_block_options_detached":false,"_editorskit_block_options_position":"{}","footnotes":""},"categories":[106,302,303],"tags":[375,330,115,261,377],"class_list":["post-17705","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-desenvolvimento","category-destaque-principal","category-destaque-secundario","tag-css","tag-desenvolvimento","tag-dicas","tag-html","tag-webdesign"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Construindo um componente HTML collapse sem usar JavaScript - SOLOWEB Tecnologia<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/\" \/>\n<meta property=\"og:locale\" content=\"pt_BR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Construindo um componente HTML collapse sem usar JavaScript - SOLOWEB Tecnologia\" \/>\n<meta property=\"og:description\" content=\"Na dica de hoje, vamos ensinar como fazer um collapse para seus sites usando apenas HTML e CSS. O collapse\" \/>\n<meta property=\"og:url\" content=\"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/\" \/>\n<meta property=\"og:site_name\" content=\"SOLOWEB Tecnologia\" \/>\n<meta property=\"article:published_time\" content=\"2023-03-17T08:51:15+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-04-02T15:28:46+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg\" \/>\n\t<meta property=\"og:image:width\" content=\"940\" \/>\n\t<meta property=\"og:image:height\" content=\"787\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Ademilton Filho\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Escrito por\" \/>\n\t<meta name=\"twitter:data1\" content=\"Ademilton Filho\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. tempo de leitura\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutos\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/\"},\"author\":{\"name\":\"Ademilton Filho\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/#\\\/schema\\\/person\\\/f868b83846c5e132dde12db8492335df\"},\"headline\":\"Construindo um componente HTML collapse sem usar JavaScript\",\"datePublished\":\"2023-03-17T08:51:15+00:00\",\"dateModified\":\"2023-04-02T15:28:46+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/\"},\"wordCount\":344,\"publisher\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/03\\\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg\",\"keywords\":[\"css\",\"desenvolvimento\",\"dicas\",\"html\",\"webdesign\"],\"articleSection\":[\"Desenvolvimento\",\"Destaque Principal\",\"Destaque Secund\u00e1rio\"],\"inLanguage\":\"pt-BR\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/\",\"url\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/\",\"name\":\"Construindo um componente HTML collapse sem usar JavaScript - SOLOWEB Tecnologia\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/03\\\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg\",\"datePublished\":\"2023-03-17T08:51:15+00:00\",\"dateModified\":\"2023-04-02T15:28:46+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/#breadcrumb\"},\"inLanguage\":\"pt-BR\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/#primaryimage\",\"url\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/03\\\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg\",\"contentUrl\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/03\\\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg\",\"width\":940,\"height\":787},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/2023\\\/03\\\/17\\\/construindo-um-componente-html-collapse-sem-usar-javascript\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"In\u00edcio\",\"item\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Construindo um componente HTML collapse sem usar JavaScript\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/\",\"name\":\"SOLOWEB Tecnologia\",\"description\":\"SOLOWEB Tecnologia\",\"publisher\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"pt-BR\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/#organization\",\"name\":\"SOLOWEB Tecnologia\",\"url\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/04\\\/cropped-solo.png\",\"contentUrl\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/04\\\/cropped-solo.png\",\"width\":341,\"height\":94,\"caption\":\"SOLOWEB Tecnologia\"},\"image\":{\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/#\\\/schema\\\/person\\\/f868b83846c5e132dde12db8492335df\",\"name\":\"Ademilton Filho\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/avatar_user_5_1674994251-96x96.png\",\"url\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/avatar_user_5_1674994251-96x96.png\",\"contentUrl\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/avatar_user_5_1674994251-96x96.png\",\"caption\":\"Ademilton Filho\"},\"sameAs\":[\"http:\\\/\\\/ademiltonsoftware.tk\"],\"url\":\"https:\\\/\\\/soloweb.com.br\\\/blog\\\/author\\\/ademilton\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Construindo um componente HTML collapse sem usar JavaScript - SOLOWEB Tecnologia","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/","og_locale":"pt_BR","og_type":"article","og_title":"Construindo um componente HTML collapse sem usar JavaScript - SOLOWEB Tecnologia","og_description":"Na dica de hoje, vamos ensinar como fazer um collapse para seus sites usando apenas HTML e CSS. O collapse","og_url":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/","og_site_name":"SOLOWEB Tecnologia","article_published_time":"2023-03-17T08:51:15+00:00","article_modified_time":"2023-04-02T15:28:46+00:00","og_image":[{"width":940,"height":787,"url":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg","type":"image\/jpeg"}],"author":"Ademilton Filho","twitter_card":"summary_large_image","twitter_misc":{"Escrito por":"Ademilton Filho","Est. tempo de leitura":"4 minutos"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/#article","isPartOf":{"@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/"},"author":{"name":"Ademilton Filho","@id":"https:\/\/soloweb.com.br\/blog\/#\/schema\/person\/f868b83846c5e132dde12db8492335df"},"headline":"Construindo um componente HTML collapse sem usar JavaScript","datePublished":"2023-03-17T08:51:15+00:00","dateModified":"2023-04-02T15:28:46+00:00","mainEntityOfPage":{"@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/"},"wordCount":344,"publisher":{"@id":"https:\/\/soloweb.com.br\/blog\/#organization"},"image":{"@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/#primaryimage"},"thumbnailUrl":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg","keywords":["css","desenvolvimento","dicas","html","webdesign"],"articleSection":["Desenvolvimento","Destaque Principal","Destaque Secund\u00e1rio"],"inLanguage":"pt-BR"},{"@type":"WebPage","@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/","url":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/","name":"Construindo um componente HTML collapse sem usar JavaScript - SOLOWEB Tecnologia","isPartOf":{"@id":"https:\/\/soloweb.com.br\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/#primaryimage"},"image":{"@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/#primaryimage"},"thumbnailUrl":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg","datePublished":"2023-03-17T08:51:15+00:00","dateModified":"2023-04-02T15:28:46+00:00","breadcrumb":{"@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/#breadcrumb"},"inLanguage":"pt-BR","potentialAction":[{"@type":"ReadAction","target":["https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/"]}]},{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/#primaryimage","url":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg","contentUrl":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/03\/WhatsApp-Image-2023-03-17-at-05.49.58.jpeg","width":940,"height":787},{"@type":"BreadcrumbList","@id":"https:\/\/soloweb.com.br\/blog\/2023\/03\/17\/construindo-um-componente-html-collapse-sem-usar-javascript\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"In\u00edcio","item":"https:\/\/soloweb.com.br\/blog\/"},{"@type":"ListItem","position":2,"name":"Construindo um componente HTML collapse sem usar JavaScript"}]},{"@type":"WebSite","@id":"https:\/\/soloweb.com.br\/blog\/#website","url":"https:\/\/soloweb.com.br\/blog\/","name":"SOLOWEB Tecnologia","description":"SOLOWEB Tecnologia","publisher":{"@id":"https:\/\/soloweb.com.br\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/soloweb.com.br\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"pt-BR"},{"@type":"Organization","@id":"https:\/\/soloweb.com.br\/blog\/#organization","name":"SOLOWEB Tecnologia","url":"https:\/\/soloweb.com.br\/blog\/","logo":{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/soloweb.com.br\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2022\/04\/cropped-solo.png","contentUrl":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2022\/04\/cropped-solo.png","width":341,"height":94,"caption":"SOLOWEB Tecnologia"},"image":{"@id":"https:\/\/soloweb.com.br\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/soloweb.com.br\/blog\/#\/schema\/person\/f868b83846c5e132dde12db8492335df","name":"Ademilton Filho","image":{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/01\/avatar_user_5_1674994251-96x96.png","url":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/01\/avatar_user_5_1674994251-96x96.png","contentUrl":"https:\/\/soloweb.com.br\/blog\/wp-content\/uploads\/2023\/01\/avatar_user_5_1674994251-96x96.png","caption":"Ademilton Filho"},"sameAs":["http:\/\/ademiltonsoftware.tk"],"url":"https:\/\/soloweb.com.br\/blog\/author\/ademilton\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/posts\/17705","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/comments?post=17705"}],"version-history":[{"count":5,"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/posts\/17705\/revisions"}],"predecessor-version":[{"id":17851,"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/posts\/17705\/revisions\/17851"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/media\/17715"}],"wp:attachment":[{"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/media?parent=17705"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/categories?post=17705"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/soloweb.com.br\/blog\/wp-json\/wp\/v2\/tags?post=17705"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}