Git Product home page Git Product logo

cockpit-files's People

Contributors

allisonkarlitskaya avatar cockpituous avatar dependabot[bot] avatar garrett avatar github-actions[bot] avatar jelly avatar kkoukiou avatar mahmoudhamdy02 avatar martinpitt avatar marusak avatar mvollmer avatar subhoghoshx avatar tomasmatus avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cockpit-files's Issues

Consider grid layout for "directories & files"

Instead of using flex, we may want to implement the grid using CSS grid, so we can have equidistant spacing and have items wrap as expected. (Using flex would mean that all items would have equidistant spacing if we changed the spacing model.) Additionally, we should be using gap, not margin, to space out items. We could also have no gap/margin, but there's probably some value in having some gutter space to deselect an item (and perhaps add canvas-style selection later on).

For example, something like this would change the spacing to rely on a grid. (We'd want to refactor it to adapt to this kind of layout, not override the PF React "Flex" as this would do. Note: PatternFly's "Grid" layout is not CSS grid; it's mainly a 12-cell design grid like Bootstrap uses, not a CSS grid as I'm suggesting here. That said, the PF Grid layout for "smart (reponsive)" may work as a basis for this... but it does a bunch of nonsense things that might also get in the way).

#folder-view {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
    justify-items: baseline;
}

.file-item,
.directory-item {
    margin: 0;
}

Impement back and forward navigation

They UI support < and > buttons. These are supposed to be navigation in history. See gnome file navigation App for understanding the expected functionality.

Rename `Create link`

I wonder if this should be more explicit and be renamed to Create symlink. Create link makes me think it generates a link to that directory/file which I could share although share link is more logical.

Fix the width of the sidebar

In smaller screens (~1300px) the sidebar jumps quite a bit and shifts the files grid. Sometimes changing from 4 columns to 3 columns while clicking on a file/folder. I've accidentally opened the wrong directory many times because of folders jumping around.

Sort directories before files

Directories should be sorted before files. Each set should have the selected sorting (alphanumeric by default, but remembering the last selected state via localstorage) applied relative to the set (of directories or folders).

For example, here's a mockup with the folders sorted before the files:

Navigator, with inline breadcrumbs (1)

Improve keyboard navigation

  • Enter should act as double click - so go into the selected directory.
  • Up / Down arrow buttons should move up/down the grid

Navigation goes crazy when permissions are restricted?

I have two users aside from root on my machine, test and kkoukiou.

[kkoukiou@sequioa cockpit-navigator-new]$ sudo ls -l /home/
total 28
drwx--x--x+ 76 kkoukiou kkoukiou  4096 Jul  7 08:04 kkoukiou
drwx------.  2 root     root     16384 Nov  1  2016 lost+found
drwx------.  9     1002     1006  4096 Jan 12 18:20 test
[kkoukiou@sequioa cockpit-navigator-new]$ sudo ls -l /home/test
total 4
drwxr-xr-x. 21 1002 1006 4096 Jan 12 17:57 cockpit

When clicking on 'test' it does not navigate inside the directory we get in the following state:

Navigator-kkoukiou-sequioa

babel js error

NODE_ENV= ./build.js
13:27:54: Build finished in 3924 ms
One of your dependencies, babel-preset-react-app, is importing the
"@babel/plugin-proposal-private-property-in-object" package without
declaring it in its dependencies. This is currently working because
"@babel/plugin-proposal-private-property-in-object" is already in your
node_modules folder for unrelated reasons, but it may break at any time.

babel-preset-react-app is part of the create-react-app project, which
is not maintianed anymore. It is thus unlikely that this bug will
ever be fixed. Add "@babel/plugin-proposal-private-property-in-object" to
your devDependencies to work around this error. This will make this message
go away.

There should be ways to select multiple files/directories

And we should allow some file operations like 'Delete' on the selection.

control-click to toggle the item as part of the selection; shift-click to make a range between last clicked and current item being shift-clicked; rubber banding, which might be difficult

File and directory items: Add selected state; improve hover state

Here's some example SCSS which adds in a selected state (based on a selected class; which needs to be added could be called something else) and retools the hover state to be similar to the selected state, using CSS custom properties ("variables"). To not interrupt flow, it uses not just background, but a box shadow and an outline (with an offset) to make the selected look expand outside of its bounding box a bit.

.file-item,
.directory-item {
    &.selected,
    &:hover {
        background: var(--item-background, transparent);
        border-radius: 1px;
        box-shadow: 0 0 0 10px var(--item-background, transparent);
        outline-offset: 10px;
        outline: 1px solid var(--item-outline, transparent);
    }

    &.selected {
        --item-background: var(--pf-global--palette--blue-50);
        --item-outline: var(--pf-global--palette--blue-50);
    }

    &:hover {
        --item-background: var(--pf-global--BackgroundColor--200);
        --item-outline: var(--pf-global--BackgroundColor--200);
    }
}

Mockups on what it should approximately look like (these are not pixel or color perfect; the code above should be similar, but not exactly like this):

Selected:

Navigator, selected

Hover:

Navigator, hover

add bookmarks

This was inspired by the 'Star' icon in the mockups.
star

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.