//  import { Meteor } from 'meteor/meteor';
import React from 'react';
import { useSubscribe, useFind, useTracker } from 'meteor/react-meteor-data/suspense';

// import { FilesCollection } from '/imports/api/files.js';
import { FilesCol } from '/imports/api/files.js';
import FileUploadStart from '/imports/ui/files/FileUploadStart.jsx';


const Files = () => {

     useSubscribe('files.all');
    
    const files = useTracker("files", () => {
        const files = FilesCol.find({}).fetchAsync();
        return files;
    });
    
    return <>
        <h1 style={{
            fontFamily: `cyber`,
            padding: `.7rem`,
            color: `#ff0c`,
            textShadow: `.02em .02em .1em black`
        }}>Files</h1>
        {
       
            <FileUploadStart />
        
        }
    </>;
};

export { Files };