@makolabs/ripple 0.0.1-dev.61 → 0.0.1-dev.62
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/adapters/storage/BaseAdapter.d.ts +20 -0
- package/dist/adapters/storage/BaseAdapter.js +171 -0
- package/dist/adapters/storage/S3Adapter.d.ts +21 -0
- package/dist/adapters/storage/S3Adapter.js +194 -0
- package/dist/adapters/storage/index.d.ts +3 -0
- package/dist/adapters/storage/index.js +3 -0
- package/dist/adapters/storage/types.d.ts +102 -0
- package/dist/adapters/storage/types.js +4 -0
- package/dist/file-browser/FileBrowser.svelte +806 -0
- package/dist/file-browser/FileBrowser.svelte.d.ts +13 -0
- package/dist/file-browser/index.d.ts +1 -0
- package/dist/file-browser/index.js +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +3 -0
- package/dist/utils/dateUtils.d.ts +7 -0
- package/dist/utils/dateUtils.js +26 -0
- package/package.json +1 -1
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { StorageAdapter, FileAction } from '../adapters/storage/index.js';
|
|
2
|
+
type $$ComponentProps = {
|
|
3
|
+
adapter: StorageAdapter;
|
|
4
|
+
startPath?: string;
|
|
5
|
+
actions?: FileAction[];
|
|
6
|
+
infoSection?: (props: {
|
|
7
|
+
selectedFiles: string[];
|
|
8
|
+
navToFileFolder: (fileKey: string) => void;
|
|
9
|
+
}) => any;
|
|
10
|
+
};
|
|
11
|
+
declare const FileBrowser: import("svelte").Component<$$ComponentProps, {}, "">;
|
|
12
|
+
type FileBrowser = ReturnType<typeof FileBrowser>;
|
|
13
|
+
export default FileBrowser;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as FileBrowser } from './FileBrowser.svelte';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as FileBrowser } from './FileBrowser.svelte';
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -71,3 +71,6 @@ export { default as Accordion } from './elements/accordion/Accordion.svelte';
|
|
|
71
71
|
export { default as Timeline } from './elements/timeline/Timeline.svelte';
|
|
72
72
|
// Re-export filters
|
|
73
73
|
export { CompactFilters } from './filters/index.js';
|
|
74
|
+
// File Browser and Storage Adapters
|
|
75
|
+
export * from './file-browser/index.js';
|
|
76
|
+
export * from './adapters/storage/index.js';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Format a date to a specific format
|
|
3
|
+
* @param date - Date to format
|
|
4
|
+
* @param format - Format string (default: 'YYYY-MM-DD')
|
|
5
|
+
* @returns Formatted date string
|
|
6
|
+
*/
|
|
7
|
+
export declare function formatDate(date: Date | string | number, formatStr?: string): string;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Format a date to a specific format
|
|
3
|
+
* @param date - Date to format
|
|
4
|
+
* @param format - Format string (default: 'YYYY-MM-DD')
|
|
5
|
+
* @returns Formatted date string
|
|
6
|
+
*/
|
|
7
|
+
export function formatDate(date, formatStr = 'DD.MM.YYYY HH:mm') {
|
|
8
|
+
const d = new Date(date);
|
|
9
|
+
if (isNaN(d.getTime())) {
|
|
10
|
+
return 'Invalid Date';
|
|
11
|
+
}
|
|
12
|
+
// Simple format implementation for common patterns
|
|
13
|
+
const day = d.getDate().toString().padStart(2, '0');
|
|
14
|
+
const month = (d.getMonth() + 1).toString().padStart(2, '0');
|
|
15
|
+
const year = d.getFullYear();
|
|
16
|
+
const hours = d.getHours().toString().padStart(2, '0');
|
|
17
|
+
const minutes = d.getMinutes().toString().padStart(2, '0');
|
|
18
|
+
const seconds = d.getSeconds().toString().padStart(2, '0');
|
|
19
|
+
return formatStr
|
|
20
|
+
.replace('DD', day)
|
|
21
|
+
.replace('MM', month)
|
|
22
|
+
.replace('YYYY', year.toString())
|
|
23
|
+
.replace('HH', hours)
|
|
24
|
+
.replace('mm', minutes)
|
|
25
|
+
.replace('ss', seconds);
|
|
26
|
+
}
|