<!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. See the LICENSE.md file in the project root for more information. -->
<!--

  This file contains Visual Studio and designer-related properties and items for F# projects.

-->

<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

  <Import Project="Microsoft.Managed.DesignTime.targets" />

  <!-- Properties -->
  <PropertyGroup>
    <AppDesignerFolder Condition="'$(AppDesignerFolder)' == ''">Properties</AppDesignerFolder>
    <AppDesignerFolderContentsVisibleOnlyInShowAllFiles Condition="'$(AppDesignerFolderContentsVisibleOnlyInShowAllFiles)' == ''">false</AppDesignerFolderContentsVisibleOnlyInShowAllFiles>
    <LanguageServiceName Condition="'$(LanguageServiceName)' == ''">F#</LanguageServiceName>
    <LanguageServiceId Condition="'$(LanguageServiceId)'==''">{BC6DD5A5-D4D6-4DAB-A00D-A51242DBAF1B}</LanguageServiceId>
    <TemplateLanguage Condition="'$(TemplateLanguage)' == ''">FSharp</TemplateLanguage>
    <AddItemTemplatesGuid Condition="'$(AddItemTemplatesGuid)' == ''">{F2A71F9B-5D33-465A-A702-920D77279786}</AddItemTemplatesGuid>
    <CmdUIContextGuid Condition="'$(CmdUIContextGuid)' == ''">{F2A71F9B-5D33-465A-A702-920D77279786}</CmdUIContextGuid>
    <GeneratorsTypeGuid Condition="'$(GeneratorsTypeGuid)' == ''">{F2A71F9B-5D33-465A-A702-920D77279786}</GeneratorsTypeGuid>
  </PropertyGroup>

  <ItemGroup>
    <PropertyPageSchema Include="$(ManagedXamlResourcesDirectory)ProjectItemsSchema.FSharp.xaml;" />

    <ProjectCapability Include="
                       FSharp;
                       Managed;
                       ProjectPropertiesEditor;" />
  </ItemGroup>

  <!-- Override rules from Microsoft.Managed.DesignTime.targets to add FullPath for TreeItemOrderPropertyProvider. -->
  <ItemGroup Condition="'$(DefineCommonManagedItemSchemas)' == 'true'">

    <PropertyPageSchema Include="$(ManagedXamlResourcesDirectory)BuildPropertyPage.FSharp.xaml">
      <Context>Project</Context>
    </PropertyPageSchema>

    <PropertyPageSchema Include="$(ManagedXamlNeutralResourcesDirectory)Compile.FSharp.xaml">
      <Context>File</Context>
    </PropertyPageSchema>

    <PropertyPageSchema Include="$(ManagedXamlNeutralResourcesDirectory)Content.FSharp.xaml">
      <Context>File</Context>
    </PropertyPageSchema>

    <PropertyPageSchema Include="$(ManagedXamlNeutralResourcesDirectory)Resource.FSharp.xaml">
      <Context>File</Context>
    </PropertyPageSchema>
    
    <PropertyPageSchema Include="$(ManagedXamlNeutralResourcesDirectory)EmbeddedResource.FSharp.xaml">
      <Context>File</Context>
    </PropertyPageSchema>

    <PropertyPageSchema Include="$(ManagedXamlNeutralResourcesDirectory)None.FSharp.xaml">
      <Context>File</Context>
    </PropertyPageSchema>

  </ItemGroup>

  <!-- Targets -->

  <!-- Returns Fsc command-line arguments for the language service -->
  <Target Name="CompileDesignTime"
          Returns="@(_CompilerCommandLineArgs)"
          DependsOnTargets="_CheckCompileDesignTimePrerequisite;Compile"
          Condition="'$(IsCrossTargetingBuild)' != 'true'"
          >

    <ItemGroup>
      <_CompilerCommandLineArgs Include="@(FscCommandLineArgs, ';');" />
    </ItemGroup>

  </Target>

</Project>