adjusted for build

This commit is contained in:
sradics 2025-05-03 12:49:46 +02:00
parent 6b2b39e83d
commit a56d2c8bbf
3 changed files with 8 additions and 3042 deletions

3040
main.js

File diff suppressed because one or more lines are too long

View file

@ -12,7 +12,7 @@ import {
FuzzySuggestModal, // Needed for the searchable folder list
FuzzyMatch // Needed for highlighting search results
} from 'obsidian';
import JSZip from 'jszip';
import JSZip from 'jszip'; // Keep this import as is with allowSyntheticDefaultImports: true
// Settings Interface
interface CourseMaterialPluginSettings {
@ -154,7 +154,7 @@ class FolderSuggestModal extends FuzzySuggestModal<TFolder> {
// ----------------------------------------
// Settings Tab Class (MODIFIED - Fetch list on button click)
// Settings Tab Class (FIXED .setCta() usage)
// ----------------------------------------
class CourseMaterialSettingTab extends PluginSettingTab {
plugin: CourseMaterialPlugin;
@ -185,7 +185,8 @@ class CourseMaterialSettingTab extends PluginSettingTab {
// Add the button to the same setting control container
setting.addButton(button => { // Add button directly to the 'setting' object
button.setButtonText('Change Folder')
.setCta(false) // Less prominent than main action buttons
// --- REMOVED .setCta(false) ---
// .setCta(false) // No argument needed, just remove if not CTA
.onClick(() => {
// --- FETCH FOLDER LIST HERE ---
console.log("Settings Tab: 'Change Folder' clicked. Fetching folder list...");

View file

@ -16,7 +16,8 @@
"ES5",
"ES6",
"ES7"
]
],
"allowSyntheticDefaultImports": true
},
"include": [
"**/*.ts"