Spaces:
Sleeping
Sleeping
Gnanashri Kota Venkatesh commited on
Update tab6.py
Browse files
tab6.py
CHANGED
|
@@ -1,190 +1,287 @@
|
|
| 1 |
import io
|
| 2 |
import os
|
| 3 |
-
import zipfile
|
| 4 |
import shutil
|
|
|
|
|
|
|
| 5 |
import streamlit as st
|
| 6 |
-
from
|
| 7 |
-
|
| 8 |
-
from helper import extract_zip_to_temp
|
| 9 |
|
| 10 |
-
ALLOWED_IMAGE_EXTENSIONS = {'.jpg', '.jpeg', '.png', '.bmp', '.gif', '.tiff', '.webp'}
|
| 11 |
-
ALLOWED_TEXT_EXTENSIONS = {'.txt', '.md', '.csv'}
|
| 12 |
-
ALLOWED_VIDEO_EXTENSIONS = {'.mp4', '.avi', '.mov', '.wmv', '.flv', '.mkv', '.webm', '.m4v', '.3gp', '.ogv'}
|
| 13 |
-
ALLOWED_AUDIO_EXTENSIONS = {'.mp3', '.wav', '.aac', '.flac', '.ogg', '.m4a', '.wma'}
|
| 14 |
-
ALL_ALLOWED_EXTENSIONS = ALLOWED_IMAGE_EXTENSIONS.union(ALLOWED_TEXT_EXTENSIONS).union(ALLOWED_VIDEO_EXTENSIONS).union(ALLOWED_AUDIO_EXTENSIONS)
|
| 15 |
|
| 16 |
|
| 17 |
-
def
|
| 18 |
-
st.header("
|
| 19 |
-
st.markdown("
|
| 20 |
-
|
| 21 |
-
#
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22 |
uploaded_file = st.file_uploader(
|
| 23 |
-
"Choose a ZIP file
|
| 24 |
type=['zip'],
|
| 25 |
-
help="Upload a zip file containing images to resize.",
|
| 26 |
-
key="resize_transparent_upload"
|
| 27 |
)
|
| 28 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 29 |
if uploaded_file:
|
| 30 |
-
#
|
| 31 |
-
st.
|
| 32 |
-
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
|
| 51 |
-
|
| 52 |
-
|
| 53 |
-
|
| 54 |
-
|
| 55 |
-
|
| 56 |
-
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
|
| 60 |
-
|
| 61 |
-
|
| 62 |
-
|
| 63 |
-
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
#
|
| 71 |
-
|
| 72 |
-
|
| 73 |
-
|
| 74 |
-
|
| 75 |
-
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
|
| 79 |
-
|
| 80 |
-
|
| 81 |
-
|
| 82 |
-
# Width is larger or equal
|
| 83 |
-
scale_factor = max_dimension / orig_w
|
| 84 |
-
new_w = max_dimension
|
| 85 |
-
new_h = int(orig_h * scale_factor)
|
| 86 |
-
else:
|
| 87 |
-
# Height is larger
|
| 88 |
-
scale_factor = max_dimension / orig_h
|
| 89 |
-
new_h = max_dimension
|
| 90 |
-
new_w = int(orig_w * scale_factor)
|
| 91 |
-
|
| 92 |
-
# Resize image while maintaining aspect ratio
|
| 93 |
-
img_resized = img.resize((new_w, new_h), PILImage.LANCZOS)
|
| 94 |
-
|
| 95 |
-
# Create transparent canvas with the exact resized dimensions
|
| 96 |
-
canvas = PILImage.new("RGBA", (new_w, new_h), (0, 0, 0, 0))
|
| 97 |
-
|
| 98 |
-
# The resized image fits perfectly on the canvas (no centering needed)
|
| 99 |
-
canvas.paste(img_resized, (0, 0), mask=img_resized)
|
| 100 |
|
| 101 |
-
|
| 102 |
-
|
| 103 |
-
|
| 104 |
-
|
| 105 |
-
|
| 106 |
-
|
| 107 |
-
|
| 108 |
-
|
| 109 |
-
|
| 110 |
-
|
| 111 |
-
|
| 112 |
-
|
| 113 |
-
|
| 114 |
-
|
| 115 |
-
|
| 116 |
-
|
| 117 |
-
|
| 118 |
-
|
| 119 |
-
|
| 120 |
-
|
| 121 |
-
|
| 122 |
-
|
| 123 |
-
|
| 124 |
-
|
| 125 |
-
|
| 126 |
-
|
| 127 |
-
|
| 128 |
-
|
| 129 |
-
|
| 130 |
-
|
| 131 |
-
|
| 132 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 133 |
|
| 134 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 135 |
|
| 136 |
-
#
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 137 |
st.download_button(
|
| 138 |
-
label="
|
| 139 |
-
data=
|
| 140 |
-
file_name="
|
| 141 |
-
mime="application/
|
| 142 |
-
key="download_resized_transparent"
|
| 143 |
)
|
| 144 |
-
|
| 145 |
-
|
| 146 |
-
|
| 147 |
-
|
| 148 |
-
|
| 149 |
-
|
| 150 |
-
|
| 151 |
-
|
| 152 |
-
|
| 153 |
-
|
| 154 |
-
|
| 155 |
-
|
| 156 |
-
|
| 157 |
-
|
| 158 |
-
|
| 159 |
-
|
| 160 |
-
|
| 161 |
-
|
| 162 |
-
|
| 163 |
-
|
| 164 |
-
|
| 165 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 166 |
else:
|
| 167 |
-
|
| 168 |
-
|
| 169 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 170 |
with st.expander("π Instructions"):
|
| 171 |
st.markdown("""
|
| 172 |
-
|
| 173 |
-
|
| 174 |
-
|
| 175 |
-
|
| 176 |
-
|
| 177 |
-
|
| 178 |
-
|
| 179 |
-
|
| 180 |
-
**Examples:**
|
| 181 |
-
- 1000x800 image β 400x320 image (width was larger)
|
| 182 |
-
- 600x1200 image β 200x400 image (height was larger)
|
| 183 |
-
- 400x400 image β 400x400 image (already correct size)
|
| 184 |
|
| 185 |
-
**
|
| 186 |
-
-
|
| 187 |
-
-
|
| 188 |
-
-
|
| 189 |
-
-
|
|
|
|
| 190 |
""")
|
|
|
|
| 1 |
import io
|
| 2 |
import os
|
|
|
|
| 3 |
import shutil
|
| 4 |
+
import zipfile
|
| 5 |
+
from pathlib import Path
|
| 6 |
import streamlit as st
|
| 7 |
+
from reportlab.lib.pagesizes import A4
|
| 8 |
+
from reportlab.lib.styles import getSampleStyleSheet
|
| 9 |
+
from helper import extract_zip_to_temp, analyze_files_by_filename, generate_filename_based_pdf_report_with_extensions, process_files, generate_excel_report
|
| 10 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 11 |
|
| 12 |
|
| 13 |
+
def brand_renamer_tool():
|
| 14 |
+
st.header("Advanced Brand File Processor")
|
| 15 |
+
st.markdown("Automatically rename and organize brand assets with numbering and generate reports.")
|
| 16 |
+
|
| 17 |
+
# Initialize session state for persistent results
|
| 18 |
+
if 'processing_complete' not in st.session_state:
|
| 19 |
+
st.session_state.processing_complete = False
|
| 20 |
+
if 'processed_data' not in st.session_state:
|
| 21 |
+
st.session_state.processed_data = {}
|
| 22 |
+
|
| 23 |
uploaded_file = st.file_uploader(
|
| 24 |
+
"Choose a ZIP file",
|
| 25 |
type=['zip'],
|
|
|
|
|
|
|
| 26 |
)
|
| 27 |
+
|
| 28 |
+
# Reset processing state when new file is uploaded
|
| 29 |
+
if uploaded_file and 'uploaded_file_name' in st.session_state:
|
| 30 |
+
if st.session_state.uploaded_file_name != uploaded_file.name:
|
| 31 |
+
st.session_state.processing_complete = False
|
| 32 |
+
st.session_state.processed_data = {}
|
| 33 |
+
|
| 34 |
if uploaded_file:
|
| 35 |
+
# Store uploaded file name to detect changes
|
| 36 |
+
st.session_state.uploaded_file_name = uploaded_file.name
|
| 37 |
+
|
| 38 |
+
if not st.session_state.processing_complete:
|
| 39 |
+
with st.spinner("Extracting and analyzing files..."):
|
| 40 |
+
temp_dir = extract_zip_to_temp(uploaded_file)
|
| 41 |
+
input_folder = Path(temp_dir)
|
| 42 |
+
|
| 43 |
+
items = os.listdir(temp_dir)
|
| 44 |
+
if len(items) == 1 and os.path.isdir(os.path.join(temp_dir, items[0])):
|
| 45 |
+
input_folder = Path(temp_dir) / items[0]
|
| 46 |
+
|
| 47 |
+
output_folder = Path(temp_dir) / "output"
|
| 48 |
+
output_folder.mkdir(exist_ok=True)
|
| 49 |
+
|
| 50 |
+
marken_set, _, _ = analyze_files_by_filename(input_folder)
|
| 51 |
+
|
| 52 |
+
if not marken_set:
|
| 53 |
+
st.error("No brands found in the uploaded files.")
|
| 54 |
+
return
|
| 55 |
+
|
| 56 |
+
st.success(f"Detected brands: {', '.join(sorted(marken_set))}")
|
| 57 |
+
|
| 58 |
+
# Brand numbering selection
|
| 59 |
+
st.subheader("Brand Numbering")
|
| 60 |
+
erste_marke = st.selectbox(
|
| 61 |
+
"Which brand should be number 01?",
|
| 62 |
+
options=sorted(marken_set),
|
| 63 |
+
index=0
|
| 64 |
+
)
|
| 65 |
+
|
| 66 |
+
marken_index = {erste_marke: "01"}
|
| 67 |
+
aktuelle_nummer = 2
|
| 68 |
+
for marke in sorted(marken_set):
|
| 69 |
+
if marke != erste_marke:
|
| 70 |
+
marken_index[marke] = f"{aktuelle_nummer:02d}"
|
| 71 |
+
aktuelle_nummer += 1
|
| 72 |
+
|
| 73 |
+
if st.button("Process Files and Generate Reports", type="primary"):
|
| 74 |
+
with st.spinner("Processing files..."):
|
| 75 |
+
# Process and rename files
|
| 76 |
+
renamed_files, file_to_factorgroup = process_files(
|
| 77 |
+
input_folder,
|
| 78 |
+
marken_index,
|
| 79 |
+
output_folder
|
| 80 |
+
)
|
| 81 |
+
|
| 82 |
+
# Rename files to preserve original extensions instead of forcing .png
|
| 83 |
+
for file_path in output_folder.iterdir():
|
| 84 |
+
if file_path.is_file():
|
| 85 |
+
# Get original extension (if it exists)
|
| 86 |
+
original_ext = file_path.suffix.lower()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 87 |
|
| 88 |
+
# If file has no extension, try to detect from content or keep as is
|
| 89 |
+
if not original_ext:
|
| 90 |
+
# Try to find original extension from renamed_files mapping
|
| 91 |
+
original_name = None
|
| 92 |
+
for folder_data in renamed_files.values():
|
| 93 |
+
for brand_data in folder_data.values():
|
| 94 |
+
for orig_path, new_name in brand_data:
|
| 95 |
+
if Path(new_name).name == file_path.name:
|
| 96 |
+
original_name = Path(orig_path).name
|
| 97 |
+
break
|
| 98 |
+
|
| 99 |
+
if original_name:
|
| 100 |
+
orig_ext = Path(original_name).suffix.lower()
|
| 101 |
+
if orig_ext:
|
| 102 |
+
new_file_path = file_path.with_suffix(orig_ext)
|
| 103 |
+
try:
|
| 104 |
+
file_path.rename(new_file_path)
|
| 105 |
+
except Exception as e:
|
| 106 |
+
print(f"Could not rename {file_path}: {e}")
|
| 107 |
+
|
| 108 |
+
# Generate PDF with extensions - supports all file types
|
| 109 |
+
pdf_buffer, error = generate_filename_based_pdf_report_with_extensions(
|
| 110 |
+
input_folder,
|
| 111 |
+
erste_marke,
|
| 112 |
+
marken_index # Pass marken_index for ID generation
|
| 113 |
+
)
|
| 114 |
+
if error:
|
| 115 |
+
st.error(f"PDF generation failed: {error}")
|
| 116 |
+
|
| 117 |
+
excel_path = generate_excel_report(output_folder, marken_index, file_to_factorgroup)
|
| 118 |
+
|
| 119 |
+
# Create individual file buffers
|
| 120 |
+
zip_buffer = io.BytesIO()
|
| 121 |
+
with zipfile.ZipFile(zip_buffer, 'w', zipfile.ZIP_DEFLATED) as zip_file:
|
| 122 |
+
for file in output_folder.iterdir():
|
| 123 |
+
if file.is_file():
|
| 124 |
+
zip_file.write(file, file.name)
|
| 125 |
+
zip_buffer.seek(0)
|
| 126 |
+
|
| 127 |
+
# Create combined download with all files
|
| 128 |
+
combined_zip_buffer = io.BytesIO()
|
| 129 |
+
with zipfile.ZipFile(combined_zip_buffer, 'w', zipfile.ZIP_DEFLATED) as combined_zip:
|
| 130 |
+
# Add processed files
|
| 131 |
+
for file in output_folder.iterdir():
|
| 132 |
+
if file.is_file():
|
| 133 |
+
combined_zip.write(file, f"processed_files/{file.name}")
|
| 134 |
+
|
| 135 |
+
# Add PDF report if available
|
| 136 |
+
if pdf_buffer:
|
| 137 |
+
combined_zip.writestr("reports/Brand_Assets_Report.pdf", pdf_buffer.getvalue())
|
| 138 |
+
|
| 139 |
+
# Add Excel report
|
| 140 |
+
with open(excel_path, 'rb') as excel_file:
|
| 141 |
+
combined_zip.writestr("reports/Brand_Assets_Overview.xlsx", excel_file.read())
|
| 142 |
+
|
| 143 |
+
combined_zip_buffer.seek(0)
|
| 144 |
+
|
| 145 |
+
# Store processed data in session state
|
| 146 |
+
st.session_state.processed_data = {
|
| 147 |
+
'pdf_buffer': pdf_buffer,
|
| 148 |
+
'excel_path': excel_path,
|
| 149 |
+
'zip_buffer': zip_buffer,
|
| 150 |
+
'combined_zip_buffer': combined_zip_buffer,
|
| 151 |
+
'temp_dir': temp_dir,
|
| 152 |
+
'renamed_files': renamed_files
|
| 153 |
+
}
|
| 154 |
+
st.session_state.processing_complete = True
|
| 155 |
+
|
| 156 |
+
# Force rerun to show download buttons
|
| 157 |
+
st.rerun()
|
| 158 |
+
|
| 159 |
+
# Show download options if processing is complete
|
| 160 |
+
if st.session_state.processing_complete:
|
| 161 |
+
st.success("Processing complete!")
|
| 162 |
+
|
| 163 |
+
# Display a preview of processed names with original extensions
|
| 164 |
+
with st.expander("Preview Processed Names"):
|
| 165 |
+
if 'renamed_files' in st.session_state.processed_data:
|
| 166 |
+
st.write("Sample processed filenames (with original extensions preserved):")
|
| 167 |
+
# Handle the case where renamed_files might be a defaultdict
|
| 168 |
+
renamed_files_data = st.session_state.processed_data['renamed_files']
|
| 169 |
|
| 170 |
+
# Extract sample file names safely
|
| 171 |
+
sample_files = []
|
| 172 |
+
if hasattr(renamed_files_data, 'items'):
|
| 173 |
+
# It's a dictionary-like object
|
| 174 |
+
for folder_name, brand_data in list(renamed_files_data.items())[:3]: # First 3 folders
|
| 175 |
+
for brand_name, files in list(brand_data.items())[:2]: # First 2 brands per folder
|
| 176 |
+
for file_path, new_name in files[:2]: # First 2 files per brand
|
| 177 |
+
if isinstance(new_name, str):
|
| 178 |
+
# Preserve original extension
|
| 179 |
+
original_ext = Path(file_path).suffix
|
| 180 |
+
pdf_name = Path(new_name).stem + original_ext
|
| 181 |
+
sample_files.append((Path(file_path).name, pdf_name))
|
| 182 |
+
if len(sample_files) >= 10:
|
| 183 |
+
break
|
| 184 |
+
if len(sample_files) >= 10:
|
| 185 |
+
break
|
| 186 |
+
if len(sample_files) >= 10:
|
| 187 |
+
break
|
| 188 |
|
| 189 |
+
# Display the sample files
|
| 190 |
+
for old_name, pdf_name in sample_files:
|
| 191 |
+
st.write(f"{old_name} β {pdf_name}")
|
| 192 |
+
|
| 193 |
+
# Option to start over
|
| 194 |
+
if st.button("π Process New File", help="Clear results and upload a new file"):
|
| 195 |
+
st.session_state.processing_complete = False
|
| 196 |
+
st.session_state.processed_data = {}
|
| 197 |
+
if 'temp_dir' in st.session_state.processed_data:
|
| 198 |
+
try:
|
| 199 |
+
shutil.rmtree(st.session_state.processed_data['temp_dir'])
|
| 200 |
+
except:
|
| 201 |
+
pass
|
| 202 |
+
st.rerun()
|
| 203 |
+
|
| 204 |
+
st.markdown("---")
|
| 205 |
+
|
| 206 |
+
# Combined download option (recommended)
|
| 207 |
+
st.subheader("π¦ Complete Package Download")
|
| 208 |
+
st.markdown("**Recommended:** Download everything in one convenient package")
|
| 209 |
+
|
| 210 |
+
if st.session_state.processed_data.get('combined_zip_buffer'):
|
| 211 |
+
st.download_button(
|
| 212 |
+
label="π Download Complete Package (All Files + Reports)",
|
| 213 |
+
data=st.session_state.processed_data['combined_zip_buffer'].getvalue(),
|
| 214 |
+
file_name="Brand_Assets_Complete_Package.zip",
|
| 215 |
+
mime="application/zip",
|
| 216 |
+
type="primary"
|
| 217 |
+
)
|
| 218 |
+
|
| 219 |
+
st.markdown("---")
|
| 220 |
+
|
| 221 |
+
# Individual download options
|
| 222 |
+
st.subheader("π Individual Downloads")
|
| 223 |
+
st.markdown("Or download items separately:")
|
| 224 |
+
|
| 225 |
+
col1, col2, col3 = st.columns(3)
|
| 226 |
+
|
| 227 |
+
with col1:
|
| 228 |
+
if st.session_state.processed_data.get('pdf_buffer'):
|
| 229 |
st.download_button(
|
| 230 |
+
label="π PDF Report",
|
| 231 |
+
data=st.session_state.processed_data['pdf_buffer'].getvalue(),
|
| 232 |
+
file_name="Brand_Assets_Report.pdf",
|
| 233 |
+
mime="application/pdf"
|
|
|
|
| 234 |
)
|
| 235 |
+
else:
|
| 236 |
+
st.info("PDF report not available")
|
| 237 |
+
|
| 238 |
+
with col2:
|
| 239 |
+
if st.session_state.processed_data.get('excel_path'):
|
| 240 |
+
try:
|
| 241 |
+
with open(st.session_state.processed_data['excel_path'], 'rb') as excel_file:
|
| 242 |
+
st.download_button(
|
| 243 |
+
label="π Excel Report",
|
| 244 |
+
data=excel_file.read(),
|
| 245 |
+
file_name="Brand_Assets_Overview.xlsx",
|
| 246 |
+
mime="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
|
| 247 |
+
)
|
| 248 |
+
except:
|
| 249 |
+
st.info("Excel report not available")
|
| 250 |
+
|
| 251 |
+
with col3:
|
| 252 |
+
if st.session_state.processed_data.get('zip_buffer'):
|
| 253 |
+
st.download_button(
|
| 254 |
+
label="π¦ Processed Files",
|
| 255 |
+
data=st.session_state.processed_data['zip_buffer'].getvalue(),
|
| 256 |
+
file_name="Brand_Assets_Processed.zip",
|
| 257 |
+
mime="application/zip"
|
| 258 |
+
)
|
| 259 |
+
|
| 260 |
+
st.markdown("---")
|
| 261 |
+
st.info("π‘ **Tip:** Downloads will remain available until you upload a new file or click 'Process New File'")
|
| 262 |
+
|
| 263 |
else:
|
| 264 |
+
# Reset session state when no file is uploaded
|
| 265 |
+
if st.session_state.processing_complete:
|
| 266 |
+
st.session_state.processing_complete = False
|
| 267 |
+
st.session_state.processed_data = {}
|
| 268 |
+
|
| 269 |
+
st.info("π Please upload a zip file to get started.")
|
| 270 |
+
|
| 271 |
with st.expander("π Instructions"):
|
| 272 |
st.markdown("""
|
| 273 |
+
Upload a ZIP file containing brand asset folders. The tool will:
|
| 274 |
+
1. Detect all brands automatically
|
| 275 |
+
2. Let you choose which brand gets number 01
|
| 276 |
+
3. Process and rename all files with proper numbering (preserving all file extensions)
|
| 277 |
+
4. Generate a PDF report showing all assets with original filenames and extensions
|
| 278 |
+
5. Create an Excel overview of the processed files (all file types)
|
| 279 |
+
6. Package everything for easy download
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 280 |
|
| 281 |
+
**Supported file types:** All extensions are supported including:
|
| 282 |
+
- Images: .png, .jpg, .jpeg, .gif, .bmp, .svg, .webp
|
| 283 |
+
- Videos: .mp4, .avi, .mov, .mkv, .webm
|
| 284 |
+
- Audio: .mp3, .wav, .ogg, .flac, .m4a
|
| 285 |
+
- Documents: .pdf, .doc, .docx, .txt, .xlsx
|
| 286 |
+
- And any other file type!
|
| 287 |
""")
|