Skip to content

Commit

Permalink
Merge pull request Sitefinity#40 from Sitefinity/DocsFeedback
Browse files Browse the repository at this point in the history
Docs feedback
  • Loading branch information
Tihomir-Petrov committed Mar 22, 2016
2 parents 2e64d70 + f9fb511 commit f174747
Show file tree
Hide file tree
Showing 12 changed files with 44 additions and 26 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

namespace AuthorWidget.MVC.Controllers
{
[ControllerToolboxItem(Name = "Author", Title = "Author", SectionName = "Custom")]
[ControllerToolboxItem(Name = "Author", Title = "Author", SectionName = "Feather samples")]
public class AuthorController : Controller
{
[TypeConverter(typeof(ExpandableObjectConverter))]
Expand Down
8 changes: 5 additions & 3 deletions AuthorWidget/readme.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
**Create a custom widget with multiple selectors**
**Create a custom widget with multiple selectors**
=====================================

The following tutorial demonstrates how to create a simple MVC Author
Expand All @@ -21,9 +21,11 @@ Installing the widget is an alternative to building it yourself. Instead of buil
1. Clone
the [feather-samples](https://github.com/Sitefinity/feather-samples) repository

2. Build the AuthorWidget project
2. Check if version of Feather nugets referenced in **AuthorWidget** project is the same as the version that you have in your project. It they are different make sure to upgrade the **AuthorWidget** project to your version.

3. Reference the AuthorWidget.dll from your Sitefinity web application
3. Build the AuthorWidget project

4. Reference the AuthorWidget.dll from your Sitefinity web application

Create the Author widget
========================
Expand Down
4 changes: 2 additions & 2 deletions BoldlessContentBlock/readme.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*Remove the "Bold" button from Content block*
*Remove the "Bold" button from Content block*
=====================================

The content block widget in Feather uses the Kendo editor
Expand All @@ -12,7 +12,7 @@ Feather Content Block widget) by replacing the default view that Feather
uses. You need to create a folder structure in your Sitefinity web
application on root level with path
**client-components\\fields\\html-field** and inside of it create a file
named ***sf-html-field.sf-cshtml**.* This way you override the default
named **sf-html-field.sf-cshtml**. This way you override the default
view for the html field which is used by the Feather Content Block
widget designer. The default file content is
[here](https://github.com/Sitefinity/feather/blob/master/Telerik.Sitefinity.Frontend/client-components/fields/html-field/sf-html-field.sf-cshtml).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

namespace CustomImageWidget.Mvc.Controllers
{
[ControllerToolboxItem(Name = "CustomImage_MVC", Title = "Custom Image", SectionName = "CustomWidgets", ModuleName = "Libraries")]
[ControllerToolboxItem(Name = "CustomImage_MVC", Title = "Custom Image", SectionName = "Feather samples", ModuleName = "Libraries")]
public class CustomImageController: Controller
{
/// <summary>
Expand Down
7 changes: 4 additions & 3 deletions CustomImageWidget/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Add image field in a custom designer view
Add image field in a custom designer view
======

The following tutorial demonstrates how to create custom MVC Image widget based on the Feather UI framework. The CustomImage widget displays an image and provide the option to upload the image through designer using build-in [sfImageFiled](http://docs.sitefinity.com/feather-image-field) component.
Expand All @@ -15,8 +15,9 @@ Installing the widget is an alternative to building it yourself.
Instead of building the widget step by step, you can get it from the repository and use it directly.

1. Clone the feather-samples repository.
2. Build the CustomImageWidget project.
3. Reference the CustomImageWidget.dll from your Sitefinity’s web application.
2. Check if version of Feather nugets referenced in **CustomImageWidget** project is the same as the version that you have in your project. It they are different make sure to upgrade the **CustomImageWidget** project to your version.
3. Build the CustomImageWidget project.
4. Reference the CustomImageWidget.dll from your Sitefinity’s web application.

# Create the Custom Image widget

Expand Down
4 changes: 2 additions & 2 deletions CustomStylesContentBlock/readme.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*Add custom styles to Content block widget*
*Add custom styles to Content block widget*
=====================================

The content block widget in Feather uses the Kendo editor
Expand All @@ -13,7 +13,7 @@ Feather Content Block widget) by replacing the default view that Feather
uses. You need to create a folder structure in your Sitefinity web
application on root level with path
**client-components\\fields\\html-field** and inside of it create a file
named ***sf-html-field.sf-cshtml**.* This way you override the default
named **sf-html-field.sf-cshtml**. This way you override the default
view for the html field which is used by the Feather Content Block
widget designer. The default file content is
[here](https://github.com/Sitefinity/feather/blob/master/Telerik.Sitefinity.Frontend/client-components/fields/html-field/sf-html-field.sf-cshtml).
Expand Down
4 changes: 2 additions & 2 deletions DynamicContentWidgetCustomDesigner/readme.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Create custom designer for dynamic content widget
Create custom designer for dynamic content widget
=====================================

All Sitefinity and Feather widgets have designers where you configure widget properties.
Expand All @@ -7,7 +7,7 @@ For more information on creating custom designer view for content controls,
see [Feather: Create custom designer views](http://docs.sitefinity.com/feather-create-custom-designer-views).

This sample requires you to create a dynamic type Countries to work.
It has to have a singilar item Country with two properties of type short text - Title and Continent.
It has to have a value for *Content type (singular)* set to *Country*, with two properties of type short text - Title and Continent.
You can use the structure and the items for the Countries module by using the Countries.zip file for the structure and the Default_Countries_items.xlsx for the items.

Create the template file
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace SimpleContentBlock.Mvc.Controllers
{
[ControllerToolboxItem(Name = "SimpleContentBlock", Title = "Simple Content Block", SectionName = "SimpleContentBlock")]
[ControllerToolboxItem(Name = "SimpleContentBlock", Title = "Simple Content Block", SectionName = "Feather samples")]
public class SimpleContentBlockController : Controller
{
public string Text { get; set; }
Expand Down
7 changes: 4 additions & 3 deletions SimpleContentBlock/readme.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*Customize the Content block toolbar*
*Customize the Content block toolbar*
=====================================

The content block widget in Feather uses the Kendo editor
Expand All @@ -23,5 +23,6 @@ as a start.
To run this sample:

1. Clone the [feather-samples](https://github.com/Sitefinity/feather-samples) repository.
4. Build the **SimpleContentBlock** project.
5. Reference the **SimpleContentBlock.dll** from your Sitefinity’s web application.
2. Check if version of Feather nugets referenced in it is the same as the version that you have in your project. It they are different make sure to upgrade the **SimpleContentBlock** project to your version.
3. Build the **SimpleContentBlock** project.
4. Reference the **SimpleContentBlock.dll** from your Sitefinity’s web application.
20 changes: 14 additions & 6 deletions SingleDynamicContent/README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
Custom widget for displaying a single dynamic content type
Custom widget for displaying a single dynamic content type
======

The following tutorial demonstrates how to create custom MVC widget for displaying single dynamic content item based on the Feather UI framework. The *Single Dynamic Content* widget provide the option to change the dynamic content type and the dynamic content item displayed in it in the designer through build-in [sfDynamicItemsSelector](http://docs.sitefinity.com/feather-dynamic-items-selector) client component.

# Install the *Single Dynamic Content* widget

1. Clone the feather-samples repository.
2. Open the SingleDynamicContent project in Visual Studio and build it.
3. Reference the SingleDynamicContent.dll from your Sitefinity’s web application.
4. Build your Sitefinity web application.
2. Open the SingleDynamicContent project in Visual Studio.
3. Check if version of Feather nugets referenced in SingleDynamicContent project is the same as the version that you have in your project. It they are different make sure to upgrade the SingleDynamicContent project to your version.
4. Build SingleDynamicContent project.
5. Reference the SingleDynamicContent.dll from your Sitefinity’s web application.
6. Build your Sitefinity web application.

# Create the *Single Dynamic Content* widget

Expand Down Expand Up @@ -122,7 +124,7 @@ Perform the following:
````

As you can see the Controller exposes public property for ItemType. By editing this property value you can change the type of dynamic content that will be displayed inside the widget. Current sample sets for default itemType *Telerik.Sitefinity.DynamicTypes.Model.Athletes.Athlete* still we are going to expose option in the widget designer to change this type during the setup of the widget.
NOTE: As you can see the Controller exposes public property for ItemType. By editing this property value you can change the type of dynamic content that will be displayed inside the widget. Current sample sets for default itemType **Telerik.Sitefinity.DynamicTypes.Model.Athletes.Athlete** still we are going to expose option in the widget designer to change this type during the setup of the widget. This way the backend user will be able to edit the ItemType by opening the widget for edit and changing the value directly in the designer.

# Create the view

Expand All @@ -134,7 +136,13 @@ To create the Default view, use the following code:
<h3>
Output some data from the model here:
@Model.Item.Id;
@if(Model.Item != null){
@Html.Raw(Model.Item.Id);
}
else{
@Html.Raw("No items found for the selected type!");
}
</h3>
````
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

namespace SingleDynamicContent.Mvc.Controllers
{
[ControllerToolboxItem(Name = "SingleDynamicContent", Title = "Single Dynamic Content", SectionName = "MvcWidgets")]
[ControllerToolboxItem(Name = "SingleDynamicContent", Title = "Single Dynamic Content", SectionName = "Feather samples")]
public class SingleDynamicContentController : Controller
{
#region Properties
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,11 @@

<h3>
Output some data from the model here:
@Model.Item.Id;

@if(Model.Item != null){
@Html.Raw(Model.Item.Id);
}
else{
@Html.Raw("No items found for the selected type!");
}
</h3>

0 comments on commit f174747

Please sign in to comment.