On `create_checkpoint` and `restore_checkpoint`, pass a path and a
`ContentsManager` to `CheckpointManager` instead of an already-loaded
model.
The `CheckpointManager` base class provides a correct implementation of
these methods that's generic across any ContentsManager, but subclasses
are free to specialize when the storage backend of `ContentsManager` is
shared.
Changed the public checkpoint API to:
- `create_checkpoint(self, nb, path)`
- `get_checkpoint_content(self, checkpoint_id, path)`
- `rename_checkpoint(self, checkpoint_id, old_path, new_path)`
- `delete_checkpoint(self, checkpoint_id, path)`
- `list_checkpoints(self, path)`
All paths in the above are API-style paths, and the `nb` argument to
`create_checkpoint` is a dictionary suitable for passing to
`nbformat.write`.
The new `get_checkpoint_content` method returns an unvalidated notebook
content dictionary. It is used by `ContentManager.restore_checkpoint`
to load content to be written via `save`.
- Add a `CheckpointManager` base class and infrastructure for creating a
`checkpoint_manager` instance attribute on `ContentsManager`.
- Provide default implementations of `delete` and `rename` in the base
`ContentsManager` class. `ContentsManager` subclasses are now
required to implement `delete_file` and `rename_file`. These methods
no longer need to manage checkpoints.
- Move checkpoint-related functionality from `FileContentsManager` to a
dedicated `FileCheckpointManager` subclass.
- Move shared filesystem interaction logic into `FileManagerMixin`
used by both `FileContentsManager` and `FileCheckpointManager`.
- Minor tweaks to ContentsManager tests to get methods from the right
object.
The purpose of this change is to provide an API for users to replace
just the checkpoint logic associated with a particular
`ContentsManager`. In particular, this change makes it possible to
easily support remote storage of checkpoints while otherwise retaining
normal filesystem interactions.
closes#7303.
Also change the arrow that indicate submenu for a fontawesoem icon,
instead of the ugly hack that show only the left border of a rectangle element
which with is twice the one of its border to get a triangle.
set a value to border-radius large, and actually make border radius
small smaller than border radius large.
Make dialog border radius coherent with the rest of the UI.
cause I want to inject some variable in it after (like border radius)
and a few other thigs.
This is just a reformating that does not change the generated css.
And do not require nemaespace either
- this is bad practice, and this prevent from
writing a blended content manager that works both
with drive and localhost as they shoudl both export
themselves to IPython.Contents module.