Skip to content

Commit

Permalink
Merge branch '4.4' into 4
Browse files Browse the repository at this point in the history
  • Loading branch information
ScopeyNZ committed Jun 16, 2019
2 parents 3712e93 + 2e33456 commit bb5b610
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 15 deletions.
16 changes: 16 additions & 0 deletions docs/en/02_Developer_Guides/00_Model/10_Versioning.md
Expand Up @@ -11,6 +11,22 @@ from published content shown to your website visitors.

Versioning in SilverStripe is handled through the [Versioned](api:SilverStripe\Versioned\Versioned) class. As a [DataExtension](api:SilverStripe\ORM\DataExtension) it is possible to be applied to any [DataObject](api:SilverStripe\ORM\DataObject) subclass. The extension class will automatically update read and write operations done via the ORM via the `augmentSQL` database hook.

<div class="notice" markdown="1">
There are two complementary modules that improve content editor experience around "owned" nested objects (e.g. elemental blocks).
Those are in experimental status right now, but we would appreciate any feedback and contributions.

You can check them out on github:
- https://github.com/silverstripe/silverstripe-versioned-snapshots
- https://github.com/silverstripe/silverstripe-versioned-snapshot-admin

The first one adds extra metadata to versions about object parents at the moment of version creation.
The second module extends CMS History UI adding control over nested objects.

<img width="600" src="../../_images/snapshot-admin.png" width="600">

*Example screenshot from versioned-snapshot-admin*
</div>

## Understanding versioning concepts

This section discuss how SilverStripe implements versioning and related high level concepts without digging into technical details.
Expand Down
2 changes: 1 addition & 1 deletion docs/en/03_Upgrading/01_Upgrading_project.md
Expand Up @@ -1235,7 +1235,7 @@ has been added to assist in migration of existing files (see [file migration doc
./vendor/bin/sake dev/tasks/MigrateFileTask
```

##### Rewriting asset references
##### Rewriting asset references{#tagtoshortcode}

Your `img` and `a` tag references to your assets may now be pointing to a location in your assets folder that has been moved. There is a task available which will look through all your tables containing `HTMLText` and `HTMLVarchar` fields looking for broken references and then rewrite them to the new location of the file.

Expand Down
3 changes: 1 addition & 2 deletions docs/en/04_Changelogs/4.4.0.md
Expand Up @@ -70,7 +70,7 @@ We have ironed out some edge cases since then:

* [Hash-less public asset URLs](#hash-less)
* [Legacy thumbnail locations](#legacy-thumb)
* TODO Shortcode migration
* [HTMLText short code migration](/Upgrading/Upgrading_projec#tagtoshortcode)


You can opt-in to performing these migration tasks on your already upgraded SilverStripe 4.x project.
Expand Down Expand Up @@ -431,7 +431,6 @@ SilverStripe\Forms\GridField\GridFieldDetailForm_ItemRequest:

### API Changes

* 2019-05-06 [8ee50d2ba](https://github.com/silverstripe/silverstripe-framework/commit/8ee50d2ba7ff582bf317de7c1149d17bab1eb4fa) Remove DataObjectSchema::getFieldMap() (#8960) (Maxime Rainville)
* 2019-05-03 [5337e6d04](https://github.com/silverstripe/silverstripe-framework/commit/5337e6d04847c66d0a293e9c6c53a58d97aea3a1) Replace FormActions with anchors to enable panel-based loading in GridField navigation buttons (#8953) (Robbie Averill)
* 2019-04-30 [d325b8a](https://github.com/silverstripe/silverstripe-assets/commit/d325b8a6e0594ba50de1033edc5b99428ed6e5dd) Mark the FlysystemAssetStore FileResolutionStrategy getters and setters as internal (#255) (Maxime Rainville)
* 2019-04-16 [3c6357d](https://github.com/silverstripe/silverstripe-assets/commit/3c6357d5856857fe21d893495071d989a8500bed) Add an extension to the regular AssetStore interface (Maxime Rainville)
Expand Down
Binary file added docs/en/_images/snapshot-admin.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
24 changes: 12 additions & 12 deletions src/View/Requirements_Backend.php
Expand Up @@ -82,14 +82,14 @@ class Requirements_Backend
protected $customScript = array();

/**
* All custom CSS rules which are inserted directly at the bottom of the HTML <head> tag
* All custom CSS rules which are inserted directly at the bottom of the HTML `<head>` tag
*
* @var array
*/
protected $customCSS = array();

/**
* All custom HTML markup which is added before the closing <head> tag, e.g. additional
* All custom HTML markup which is added before the closing `<head>` tag, e.g. additional
* metatags.
*
* @var array
Expand Down Expand Up @@ -148,8 +148,8 @@ class Requirements_Backend
protected $combinedFilesFolder = null;

/**
* Put all JavaScript includes at the bottom of the template before the closing <body> tag,
* rather than the default behaviour of placing them at the end of the <head> tag. This means
* Put all JavaScript includes at the bottom of the template before the closing `<body>` tag,
* rather than the default behaviour of placing them at the end of the `<head>` tag. This means
* script downloads won't block other HTTP requests, which can be a performance improvement.
*
* @var bool
Expand Down Expand Up @@ -522,7 +522,7 @@ protected function getAllJavascript()
/**
* Register the given JavaScript code into the list of requirements
*
* @param string $script The script content as a string (without enclosing <script> tag)
* @param string $script The script content as a string (without enclosing `<script>` tag)
* @param string $uniquenessID A unique ID that ensures a piece of code is only added once
*/
public function customScript($script, $uniquenessID = null)
Expand All @@ -547,7 +547,7 @@ public function getCustomScripts()
/**
* Register the given CSS styles into the list of requirements
*
* @param string $script CSS selectors as a string (without enclosing <style> tag)
* @param string $script CSS selectors as a string (without enclosing `<style>` tag)
* @param string $uniquenessID A unique ID that ensures a piece of code is only added once
*/
public function customCSS($script, $uniquenessID = null)
Expand All @@ -570,7 +570,7 @@ public function getCustomCSS()
}

/**
* Add the following custom HTML code to the <head> section of the page
* Add the following custom HTML code to the `<head>` section of the page
*
* @param string $html Custom HTML code
* @param string $uniquenessID A unique ID that ensures a piece of code is only added once
Expand Down Expand Up @@ -868,9 +868,9 @@ public function includeInHTML($content)

/**
* Given a block of HTML, insert the given scripts at the bottom before
* the closing </body> tag
* the closing `</body>` tag
*
* @param string $jsRequirements String containing one or more javascript <script /> tags
* @param string $jsRequirements String containing one or more javascript `<script />` tags
* @param string $content HTML body
* @return string Merged HTML
*/
Expand All @@ -887,9 +887,9 @@ protected function insertScriptsAtBottom($jsRequirements, $content)
}

/**
* Given a block of HTML, insert the given scripts inside the <body></body>
* Given a block of HTML, insert the given scripts inside the `<body></body>`
*
* @param string $jsRequirements String containing one or more javascript <script /> tags
* @param string $jsRequirements String containing one or more javascript `<script />` tags
* @param string $content HTML body
* @return string Merged HTML
*/
Expand Down Expand Up @@ -924,7 +924,7 @@ protected function insertScriptsIntoBody($jsRequirements, $content)
}

/**
* Given a block of HTML, insert the given code inside the <head></head> block
* Given a block of HTML, insert the given code inside the `<head></head>` block
*
* @param string $jsRequirements String containing one or more html tags
* @param string $content HTML body
Expand Down

0 comments on commit bb5b610

Please sign in to comment.