backdrop-contrib / tatsu

A basic flexible theme inspired by Basis theme in Backdrop CMS Core
GNU General Public License v2.0
2 stars 5 forks source link

Should sub-theme be required #48

Open stpaultim opened 5 years ago

stpaultim commented 5 years ago

As I started to experiment with a sub-theming starter kit this weekend, it occurred to me that maybe a sub-theme should be required for things like color module support. Why keep copies of the color module file in both Tatsu and the sub-theme, if we expect most/all users to create a sub-theme.

1) When I completely moved color module support to the sub-theme, I ran into technical problems

2) As I think about use cases, I can imagine that some users will be able to benefit from Tatsu without the need or skills to create a sub-theme. I don't think I want to require that, but I'm open to feedback.

Created this issue to get feedback, but I don't think I want to require users to create a sub-theme if they use Tatsu.

izmeez commented 1 year ago

With tatsu 1.x-2.x added color into the subtheme and ran into problems. Didn't have problems when doing it with the Basis theme. Preview window displays Fatal error: Fatal error: Uncaught ValueError: Path cannot be empty in ...\core\modules\color\color.module:189 Stack trace: #0 ...\core\modules\color\color.module(189): file_get_contents('') #1 ...\core\includes\module.inc(1200): color_css_alter(Array, NULL, NULL, NULL) #2 ...\core\includes\common.inc(3583): backdrop_alter('css', Array) #3 ...\core\modules\system\templates\maintenance-page.tpl.php(21): backdrop_get_css() #4 ...\core\includes\theme.inc(1559): include('...') #5 ...\core\includes\theme.inc(1218): theme_render_template('core/modules/sy...', Array) #6 ...\core\includes\errors.inc(256): theme('maintenance_pag...', Array) #7 ...\core\includes\bootstrap.inc(2989): _backdrop_log_error(Array, true) #8 [internal function]: _backdrop_exception_handler(Object(ValueError)) #9 {main} thrown in ...\core\modules\color\color.module on line 189

And saving the change displays numerous errors of deprecated functions and warnings like: Deprecated function: file_get_contents(): Passing null to parameter #1 ($filename) of type string is deprecated in color_css_alter() (line 189 of ...\core\modules\color\color.module). Deprecated function: file_exists(): Passing null to parameter #1 ($filename) of type string is deprecated in color_save_configuration() (line 621 of ...\core\modules\color\color.module).

None of this happens with changing colors in the theme itself.

Wylbur commented 12 months ago

Testing today:

@izmeez When you did your testing, was the color module enabled?

izmeez commented 10 months ago

Been out of the loop for awhile. I'll have to revisit this.