Folder for new code components
>>> [!note] Migrated issue
<!-- Drupal.org comment -->
<!-- Migrated from issue #3540581. -->
Reported by: [balintbrews](https://www.drupal.org/user/613760)
Related to !447
>>>
<h3 id="overview">Overview</h3>
<p>Allow code component authors to create a folder inline rather than creating in a separate popup box.</p>
<p>→ See: <span class="drupalorg-gitlab-issue-link drupalorg-gitlab-link-wrapper"><a href="https://git.drupalcode.org/project/canvas/-/work_items/3540576" class="drupalorg-gitlab-link">https://git.drupalcode.org/project/canvas/-/work_items/3540576</a></span></p>
<h3 id="proposed-resolution">Proposed resolution</h3>
<ol>
<li>Create folder inline.</li>
<li>Allow creating a new folder. Handle potential name collisions the same way it was handled in <span class="drupalorg-gitlab-issue-link project-issue-status-info project-issue-status-7"><a href="https://www.drupal.org/project/experience_builder/issues/3540577" title="Status: Closed (fixed)">#3540577: Displaying and creating folders</a></span>.</li>
</ol>
<h3 id="acceptance-criteria">Acceptance Criteria</h3>
<ol>
<li><strong>Add folder option visibility</strong></li>
<p>Given the user is on code component section tab<br>
Then an “Add folder“ option must visible along with “Add component“ option</p>
<li><strong>Create folder on click</strong></li>
<p>Given the user is on code component section tab<br>
When the user clicks on “Add folder“<br>
Then a new folder must be created under the listing by following the design</p>
<li><strong>Default folder state</strong></li>
<p>Given a folder is created<br>
Then the folder must<br>
Appear in the folder list immediately<br>
Display a count value of 0(Zero) that indicate that there are no component inside the folder
</p></ol>
<h3 id="ui-changes">User interface changes</h3>
<p><em>The folder will create inline rather than in a separate popup box.</em></p>
> Related issue: [Issue #3540577](https://www.drupal.org/node/3540577)
> Related issue: [Issue #3540576](https://www.drupal.org/node/3540576)
issue