bratislava / bratislava.sk

Frontend & CMS server of the new bratislava.sk website.
https://bratislava.sk
European Union Public License 1.2
26 stars 3 forks source link

Update `FileList` according to DS #1299

Closed radoslavzeman closed 2 months ago

radoslavzeman commented 2 months ago

This task is about FileList component with rows variant.

Note: Do not change anything for grid variant, as it is deprecated at will be removed completely in further tasks.

https://www.figma.com/design/17wbd0MDQcMW9NbXl6UPs8/DS-ESBS%2BBK%3A-Component-library?node-id=14810-27580&t=I4o9JVmjSWHb7kak-0

Relevant current code:

            {variantFileList === 'rows' && (
              <div className="mt-4 flex flex-col lg:mt-6">
                {fileSection?.files.map((file, fileIndex) => (
                  // eslint-disable-next-line react/no-array-index-key
                  <div key={fileIndex} className="w-full">
                    <FileCardWrapper fileItem={file} variant={variantFileList} />
                  </div>
                ))}
              </div>
            )}

Update the component according to DS - add border and vertical padding (py). Note: We will probably want to have the "parent" div implemented as separated component, but it will be assigned as separate task (we will wait until it is done in figma).

Additionally, we want to render the file list as actual html list (unordered). Please change the parent div to ul and item's "wrapping" div to li.

Image