wp-papi / papi

:rocket: WordPress Page Type API with custom fields
https://wp-papi.github.io
MIT License
263 stars 32 forks source link

Module property #254

Closed frozzare closed 6 years ago

frozzare commented 6 years ago

Description

Module property that takes a mindset and create a property of it.

The mindset is about: You have a post type that is called module where you have many different page types that acts like modules that can be chosen in a property that can handle posts. This property can only be used with one post type (module is default), the great thing about the property is that you can select different templates for when you select a module and not only when you create your template.

A new type has been added Papi_Module_Type that extends Papi_Page_Type, not so big different right now but maybe in the feature. Right now it's just for showing of the different between a page type and a module type even if both are posts.

Checklist

codecov-io commented 6 years ago

Codecov Report

Merging #254 into master will increase coverage by 0.01%. The diff coverage is 83.09%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master     #254      +/-   ##
============================================
+ Coverage     90.18%   90.19%   +0.01%     
- Complexity     2030     2076      +46     
============================================
  Files            96       97       +1     
  Lines          6186     6326     +140     
============================================
+ Hits           5579     5706     +127     
- Misses          607      620      +13
Impacted Files Coverage Δ Complexity Δ
src/properties/class-papi-property-post.php 81.33% <ø> (ø) 61 <0> (ø) :arrow_down:
src/admin/class-papi-admin-ajax.php 95.23% <100%> (+0.27%) 53 <2> (+2) :arrow_up:
src/lib/types/entry.php 99.37% <100%> (+0.08%) 0 <0> (ø) :arrow_down:
src/properties/class-papi-property-module.php 78.94% <78.94%> (ø) 44 <44> (?)
src/core/class-papi-core-data-handler.php 95.74% <0%> (+2.12%) 34% <0%> (ø) :arrow_down:
src/properties/class-papi-property-repeater.php 87.82% <0%> (+2.33%) 142% <0%> (ø) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 5e8089b...33f456e. Read the comment docs.