Skip to content
This repository has been archived by the owner on Mar 15, 2022. It is now read-only.

Commit

Permalink
Change theme version, update authenticatedusersnippet and iframesnippet
Browse files Browse the repository at this point in the history
  • Loading branch information
georgeroubie committed Oct 23, 2017
1 parent 58364bb commit d022fe4
Show file tree
Hide file tree
Showing 8 changed files with 51 additions and 13 deletions.
10 changes: 8 additions & 2 deletions ResponsiveThemeForDevelopers.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@
<Content Include="Theme.png" />
<Content Include="Theme.txt" />
<Content Include="ThemeZonePreview.png" />
<Content Include="Views\Elements\AuthenticatedUserSnippet.txt" />
<Content Include="Views\Elements\iFrameSnippet.txt" />
<Content Include="Web.config" />
<Content Include="js\Web.config" />
<Content Include="img\Web.config" />
Expand All @@ -137,15 +139,13 @@
<Content Include="Views\BlogPost.Title.Summary.cshtml" />
<Content Include="Views\Document.cshtml" />
<Content Include="Views\Dropdown.cshtml" />
<Content Include="Views\Elements\AuthenticatedUserSnippet.cshtml" />
<Content Include="Views\Elements\Checkbox.cshtml" />
<Content Include="Views\Elements\Column.cshtml" />
<Content Include="Views\Elements\Enumeration-CheckList.cshtml" />
<Content Include="Views\Elements\Enumeration-RadioList.cshtml" />
<Content Include="Views\Elements\Form.cshtml" />
<Content Include="Views\Elements\Grid.cshtml" />
<Content Include="Views\Elements\Image.cshtml" />
<Content Include="Views\Elements\ResponsiveIframeSnippet.cshtml" />
<Content Include="Views\Elements\ShareButtonSnippet.cshtml" />
<Content Include="Views\ErrorPage.cshtml" />
<Content Include="Views\Layout.cshtml" />
Expand Down Expand Up @@ -235,6 +235,12 @@
<ItemGroup>
<Content Include="scss\components\_tags.scss" />
</ItemGroup>
<ItemGroup>
<Content Include="Views\Elements\iFrameSnippet.cshtml" />
</ItemGroup>
<ItemGroup>
<Content Include="Views\Elements\AuthenticatedUserSnippet.cshtml" />
</ItemGroup>
<PropertyGroup>
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
Expand Down
2 changes: 1 addition & 1 deletion Theme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ Name: ResponsiveThemeForDevelopers
Author: George Roubie
Website: https://gr.linkedin.com/in/georgeroubie
Description: Responsive Theme optimized for Orchard 1.10.2
Version: 1.3.1
Version: 1.4.0
Tags: Theme, Responsive, Bootstrap, jQuery, JS, JavaScript, Sass, Orchard, Toastr, FontAwesome, Developer, CSS, Gulp, npm
Zones: Header, Navigation, BeforeMain, Featured, AsideFirst, Messages, BeforeContent, Content, AfterContent, AsideSecond, AfterMain, TripelFirst, TripelSecond, TripelThird, FooterQuadFirst, FooterQuadSecond, FooterQuadThird, FooterQuadFourth, Footer
7 changes: 6 additions & 1 deletion Views/Elements/AuthenticatedUserSnippet.cshtml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
@{
string redirectUrl = Model.URL;
if (WorkContext.CurrentUser == null)
{
Response.Redirect("~/Users/Account/LogOn");
if(String.IsNullOrEmpty(redirectUrl)) {
Response.Redirect("~/Users/Account/LogOn");
} else {
Response.Redirect("~/" + redirectUrl);
}
}
}
9 changes: 9 additions & 0 deletions Views/Elements/AuthenticatedUserSnippet.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
DisplayName: Authenticated User
ToolboxIcon: \uf007
Description: Authenticated User Snippet
Category: Snippets
Fields:
- Name: URL
DisplayName: URL
Description: If the user is not authenticated will be redirected to this url. Leave empty for default.
Type: Text
7 changes: 0 additions & 7 deletions Views/Elements/ResponsiveIframeSnippet.cshtml

This file was deleted.

12 changes: 12 additions & 0 deletions Views/Elements/iFrameSnippet.cshtml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
@{
string url = Model.URL;
string ratio = Model.Ratio;
if(ratio != "16by9" && ratio != "4by3") {
ratio = "4by3";
}
}
@if (!String.IsNullOrEmpty(url)) {
<div class="embed-responsive embed-responsive-@ratio">
<iframe class="embed-responsive-item" src="@url" allowfullscreen></iframe>
</div>
}
13 changes: 13 additions & 0 deletions Views/Elements/iFrameSnippet.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
DisplayName: iFrame
ToolboxIcon: \uf1c9
Description: iFrame Snippet
Category: Snippets
Fields:
- Name: URL
DisplayName: URL
Description: Enter here the iFrame URL of your provider.
Type: Text
- Name: Ratio
DisplayName: Ratio
Description: Enter the ratio of iFrame 16by9 or 4by3. Leave empty for default.
Type: Text
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "responsive-theme-for-developers",
"version": "1.3.1",
"name": "responsive-theme-for-developers-orchard-cms",
"version": "1.4.0",
"description": "Responsive Orchard CMS theme for developers",
"main": "Document.cshtml",
"scripts": {
Expand Down

0 comments on commit d022fe4

Please sign in to comment.