From 88f38b76e274c9bc9b0b6c7fa8c30c17de3e66ea Mon Sep 17 00:00:00 2001 From: axllent Date: Wed, 18 Oct 2017 10:54:00 +1300 Subject: [PATCH] Switch to silverstripe-vendormodule --- CHANGELOG.md | 10 +++++++++- composer.json | 10 ++++++++-- src/LeftAndMainTiledGridFieldExt.php | 8 +------- 3 files changed, 18 insertions(+), 10 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 86cebac..55264ee 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,18 +2,26 @@ Notable changes to this project will be documented in this file. +## [2.0.2] + +- Switch to silverstripe-vendormodule + + ## [2.0.1] - Fix padding & add hover effect + ## [2.0.0] -- - Support for SilverStripe 4 +- Support for SilverStripe 4 + ## [1.1.0] - Fix SilverStripe framework version requirement + ## [1.0.0] - Adopt semantic versioning releases diff --git a/composer.json b/composer.json index fe15c32..528b0cc 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "axllent/silverstripe-tiled-gridfield", "description": "Inline/tiled images in a SilverStripe GridField table", - "type": "silverstripe-module", + "type": "silverstripe-vendormodule", "homepage": "https://github.com/axllent/silverstripe-tiled-gridfield", "keywords": [ "silverstripe", @@ -21,8 +21,14 @@ "issues": "https://github.com/axllent/silverstripe-tiled-gridfield/issues" }, "require": { - "silverstripe/framework": "^4.0@dev" + "silverstripe/vendor-plugin": "^1.0", + "silverstripe/framework": "^4.0" }, + "extra": { + "expose": [ + "css" + ] + }, "autoload": { "psr-4": { "Axllent\\TiledGridField\\": "src/" diff --git a/src/LeftAndMainTiledGridFieldExt.php b/src/LeftAndMainTiledGridFieldExt.php index 048214c..6e0f92a 100644 --- a/src/LeftAndMainTiledGridFieldExt.php +++ b/src/LeftAndMainTiledGridFieldExt.php @@ -10,15 +10,9 @@ */ class LeftAndMainTiledGridFieldExt extends LeftAndMainExtension { - public function init() { parent::init(); - Requirements::css($this->ModuleBase() . '/css/tiled-gridfield.css'); - } - - private function ModuleBase() - { - return basename(dirname(dirname(__FILE__))); + Requirements::css('axllent/silverstripe-tiled-gridfield: css/tiled-gridfield.css'); } }